projects
/
monky
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
af55c4a
)
Bugfix: sometimes segfaults with cpubar
author
Nikolas Garofil
<garo@dunaldi.garofil.be>
Thu, 7 May 2009 16:44:45 +0000
(18:44 +0200)
committer
Nikolas Garofil
<garo@dunaldi.garofil.be>
Thu, 7 May 2009 16:44:45 +0000
(18:44 +0200)
src/conky.c
patch
|
blob
|
history
diff --git
a/src/conky.c
b/src/conky.c
index
020eb4e
..
fef2555
100644
(file)
--- a/
src/conky.c
+++ b/
src/conky.c
@@
-1296,7
+1296,7
@@
static struct text_object *construct_text_object(const char *s,
END OBJ(cached, INFO_BUFFERS)
#define SCAN_CPU(__arg, __var) { \
int __offset; \
- if (__arg && sscanf(__arg, " cpu%u %n", &__var, &__offset)) \
+ if (__arg && sscanf(__arg, " cpu%u %n", &__var, &__offset) == 2) \
__arg += __offset; \
else \
__var = 0; \