- sprintf(part, "%s %s: %s", (running ? concat("#00FF00 ", wmii_normcolors) : concat("#FF0000 ", wmii_normcolors)), run_watches[i], (running ? "yes" : "no"));
- else sprintf(part, "%s: %s", run_watches[i], (running ? "yes" : "no"));
- sprintf(pathbuf, "%s%s", order[ORDER_RUN], run_watches[i]);
+ snprintf(part, sizeof(part), "%s %s: %s",
+ (running ?
+ concat("#00FF00 ", wmii_normcolors) :
+ concat("#FF0000 ", wmii_normcolors)),
+ run_watches[i],
+ (running ? "yes" : "no"));
+ else snprintf(part, sizeof(part), "%s: %s", run_watches[i], (running ? "yes" : "no"));
+ snprintf(pathbuf, sizeof(pathbuf), "%s%s", order[ORDER_RUN], run_watches[i]);