| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`MB_CUR_MAX` looks like a macro, but it's a function call and therefore
creates a VLA. We don't want that.
Also this array being uninitialized created the following Valgrind error
```
==503529== Conditional jump or move depends on uninitialised value(s)
==503529== at 0x619F15E: waddnstr (lib_addstr.c:67)
==503529== by 0x1929B7: _inp_write (inputwin.c:353)
==503529== by 0x1937D5: _inp_redisplay (inputwin.c:619)
==503529== by 0x61511B1: rl_forced_update_display (display.c:2693)
==503529== by 0x193F9D: _inp_rl_send_to_editor (inputwin.c:957)
==503529== by 0x614642F: _rl_dispatch_subseq (readline.c:916)
==503529== by 0x6146C85: _rl_dispatch_callback (readline.c:823)
==503529== by 0x616739F: rl_callback_read_char (callback.c:241)
==503529== by 0x1923DB: inp_readline (inputwin.c:188)
==503529== by 0x149860: prof_run (profanity.c:117)
==503529== by 0x2283E8: main (main.c:186)
==503529== Uninitialised value was created by a stack allocation
==503529== at 0x1928B1: _inp_write (inputwin.c:334)
```
Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
|
|
|
|
| |
Introduced in 59b99fece.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Expected behaviour
When you type
/command
/command
it should be just 1 entry in the history.
Behaviour
All the entries were saved.
Behaviour is changed by introducing check. Before adding to history,
entry now is compared to the last history entry.
|
|
|
|
|
|
| |
This let's us whole `/me` messages and other messages starting with `>`.
Fix https://github.com/profanity-im/profanity/issues/1732
|
|
|
|
|
|
|
|
|
| |
When editing multi-line messages or comments everything past the first
newline becomes invisible.
This patch fixes it by substituting a Unicode symbol for "return"
instead of printing the newline as is. On locales where it's not
available single backslash is used instead.
|
|
|
|
|
| |
Allow Readline to control when to redisplay the input line. This makes
text entered via /editor visible after editor is closed.
|
|
|
|
|
| |
When doing an interactive search the prompt is needed to show the
current state of the search to avoid confusion.
|
|\
| |
| | |
Tab completion code simplification
|
| |
| |
| |
| |
| |
| | |
Factor out common code for Tab and Shift-Tab in a separate function.
No functional change.
|
|\ \
| | |
| | | |
Add Alt/Ctrl-arrows combinations for GNU Screen
|
| |/
| |
| |
| |
| |
| | |
GNU Screen terminal emulator is modelled after VT100, its key bindings
for "application mode" (which profanity enables on startup) can be
seen with this: info screen "Input Translation".
|
|/ |
|
|
|
|
|
|
|
|
|
|
| |
The current code enters an infinite loop if the input string happens
to get an invalid utf-8 sequence somehow. For me it was reproducible
by running profanity in a Screen session and pressing Alt-т (cyrillic
letter).
Fix it the way borrowed from 0501e49623f68aa39508e4e622924c1dd8147588
where mbrlen is used for the same purposes.
|
|
|
|
|
|
|
|
|
|
| |
Fixes https://github.com/profanity-im/profanity/issues/1649
Type `>` then press tab or shift tab to autocomplete previous messages,
then type your reply and send message.
Newlines are replaced with newline followed by `> `.
A newline is added at the end so that the user can immediately type a
message without manually adding a new line.
|
|\
| |
| | |
Fix not autocompleting nicks with '/'
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
Remove check for '/' at the beginning of the line before autocompleting
and make it fallback to command autocompletion if no nicks found.
Fixes https://github.com/profanity-im/profanity/issues/1474
|
| |
| |
| |
| | |
Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
|
| | |
|
|/ |
|
| |
|
|
|
|
|
|
| |
alt+f is the default readline shortcut for forward one word.
Regards https://github.com/profanity-im/profanity/issues/1580
|
|
|
|
|
| |
When the user enables or disabled the attention flag, a message will be
displayed in the chat window.
|
| |
|
|
|
|
| |
Attention flag for groupchat and display the windows via "/wins attention"
|
|
|
|
|
|
|
| |
User is able to toggle a flag for chat windows. This flag should be used to mark
the window for "Attention".
Use Ctrl+f to mark the window.
|
|
|
|
| |
Input window size was one cell off, therefore terminal themes with background color set were rendered incorrectly, fixes #1458
|
| |
|
|
|
|
|
|
|
|
| |
This allows profanity to work without segfaulting from NULL
pointer dereferences when used with NetBSD libcurses.
Basic functionality was tested, there may be more NULL pointer
issues hiding.
|
|
|
|
|
|
| |
- Add NetBSD as a recognized platform without -ldl.
- Allow building with NetBSD libcurses instead of ncurses.
- Portability to NetBSD sh - use POSIX '=' instead of '=='.
|
| |
|
|
|
|
|
|
| |
This reverts commit 9b55f2dec0ea27a9ce4856e303425e12f866cea2.
Sorting the includes creates some problems.
|
|
|
|
| |
Regards https://github.com/profanity-im/profanity/issues/1396
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
https://github.com/profanity-im/profanity/commit/98c38dc6d6d29333c63f80327774f094610d8602
sets C99 as standard.
strdup() is not part of C99.
For now set `-D_POSIX_C_SOURCE=200809L` macro to have strdup() in C99.
Using `gnu99` instead would be another option.
We should take more care to use glib functions whenever possible.
Regards https://github.com/profanity-im/profanity/issues/1357
|
|
|
|
| |
Protect against invalid reads by checking the length.
|
| |
|
|
|
|
|
| |
New command `/slashguard` tries to protect against typing ` /quit` by
not allowing a slash in the first 4 characters.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[Programming with GNU
History](http://www.math.utah.edu/docs/info/hist_2.html) mentions
using_history().
Chet, maintainer of readline told me about it. (Thanks Chet!)
Seems like we need to call this so that the history offset is at the
right end of the list. I assume it's called in the linehandler
automatically.
Fix https://github.com/profanity-im/profanity/issues/200
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Regards https://github.com/profanity-im/profanity/issues/200
This doesn't work yet. And I have no idea why.
Weird behaviour:
- start profanity
- type 'ASDF'
- ctrl+arrow down
-> text vanishes (like intended)
- arrow up
-> nothing happens (intended is that the last history item [ASDF]
appears)
- type 'ABC'
- press enter
- arrow up
-> ABC appears
- enter
- type 'UUU'
- ctrl+arrow down
- type 'ZZZ'
- enter
- arrow up
- ZZZ appears
- arrow up
- UUU appears
So in the latter case we added to history and deleted from the input
line and then immediately entered new text and pressed enter, to add
this to the history too.
When we do this the not sent text succesfully was stored in history.
|
|
|
|
|
|
| |
alt-a brings one to the next window with unread messages.
Regards https://github.com/profanity-im/profanity/issues/1114
|
|
|
|
|
|
|
|
|
|
| |
alt-2 brings one ot the window.
irssi supports alt + 1234567890qwertyuio to easily switch to 20 windows
instead of just ten.
Hardcode this too.
Regards https://github.com/profanity-im/profanity/issues/1114
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|