projects
/
suckless
/
dwm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e5765cd
)
pneubeck pointed out an obvious thing, that a second p = stext + strlen(stext) -...
author
Anselm R. Garbe
<arg@suckless.org>
Fri, 9 Feb 2007 13:56:19 +0000
(14:56 +0100)
committer
Anselm R. Garbe
<arg@suckless.org>
Fri, 9 Feb 2007 13:56:19 +0000
(14:56 +0100)
main.c
patch
|
blob
|
history
diff --git
a/main.c
b/main.c
index 1fd7ab1329df38bff3ebfb78d6eed4122fe12617..02475e0f102f4880622b2076ac4a17368132e8ab 100644
(file)
--- a/
main.c
+++ b/
main.c
@@
-273,7
+273,7
@@
main(int argc, char *argv[]) {
break;
default:
for(stext[r] = '\0', p = stext + strlen(stext) - 1; p >= stext && *p == '\n'; *p-- = '\0');
- for(
p = stext + strlen(stext) - 1
; p >= stext && *p != '\n'; --p);
+ for(; p >= stext && *p != '\n'; --p);
if(p > stext)
strncpy(stext, p + 1, sizeof stext);
}