Skip to content

Commit 42fc113

Browse files
Daniel Lowegitster
authored andcommitted
Fix non-literal format in printf-style calls
These were found using gcc 4.3.2-1ubuntu11 with the warning: warning: format not a string literal and no format arguments Signed-off-by: Junio C Hamano <[email protected]>
1 parent 8bb4646 commit 42fc113

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

builtin-check-attr.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ int cmd_check_attr(int argc, const char **argv, const char *prefix)
9797
else if (stdin_paths && doubledash < argc)
9898
errstr = "Can't specify files with --stdin";
9999
if (errstr) {
100-
error (errstr);
100+
error("%s", errstr);
101101
usage_with_options(check_attr_usage, check_attr_options);
102102
}
103103

hash-object.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ int main(int argc, const char **argv)
110110
}
111111

112112
if (errstr) {
113-
error (errstr);
113+
error("%s", errstr);
114114
usage_with_options(hash_object_usage, hash_object_options);
115115
}
116116

0 commit comments

Comments
 (0)