Skip to content

Commit 0f3df6e

Browse files
committed
satisfy -Werror=format-security
1 parent 6bab626 commit 0f3df6e

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/rp.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,19 +46,18 @@ int rp_startupWintasks()
4646
ratpoison_cmd = (char *)malloc(MAXPATHSZ); // we don't free it, hopefully run only once
4747
FILE *fp;
4848
char *fr;
49-
char *errpr = "can't find ratpoison executable\n";
5049
// search in PATH on startup only,
5150
// then execv() for speed
5251
if ((fp = popen("which ratpoison", "r"))) {
5352
fr = fgets(ratpoison_cmd, MAXPATHSZ, fp);
5453
if (fr == NULL) {
55-
fprintf(stderr, errpr);
54+
fprintf(stderr, "can't find ratpoison executable\n");
5655
return 0;
5756
}
5857
pclose(fp);
5958
}
6059
if (strlen(ratpoison_cmd) < 2) {
61-
fprintf(stderr, errpr);
60+
fprintf(stderr, "can't find ratpoison executable\n");
6261
return 0;
6362
} else {
6463
ratpoison_cmd[strcspn(ratpoison_cmd, "\r\n")] = 0;

0 commit comments

Comments
 (0)