Browse Source

applied Alex Sedov's Tab buffer termination patch, thanks

master
Anselm R Garbe 12 years ago
parent
commit
ec64f273fb
  1. 3
      dmenu.c

3
dmenu.c

@ -392,7 +392,8 @@ keypress(XKeyEvent *ev) {
case XK_Tab:
if(!sel)
return;
strncpy(text, sel->text, sizeof text);
strncpy(text, sel->text, sizeof text - 1);
text[sizeof text - 1] = '\0';
cursor = strlen(text);
match();
break;

Loading…
Cancel
Save