summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 86747c1)
raw | patch | inline | side by side (parent: 86747c1)
author | Theodore Ts'o <tytso@mit.edu> | |
Fri, 30 Mar 2007 23:07:05 +0000 (19:07 -0400) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sat, 31 Mar 2007 08:11:11 +0000 (01:11 -0700) |
This fixes a problem reported by Randal Schwartz:
>I finally tracked down all the (albeit inconsequential) errors I was getting
>on both OpenBSD and OSX. It's the warn() function in usage.c. There's
>warn(3) in BSD-style distros. It'd take a "great rename" to change it, but if
>someone with better C skills than I have could do that, my linker and I would
>appreciate it.
It was annoying to me, too, when I was doing some mergetool testing on
Mac OS X, so here's a fix.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Cc: "Randal L. Schwartz" <merlyn@stonehenge.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
>I finally tracked down all the (albeit inconsequential) errors I was getting
>on both OpenBSD and OSX. It's the warn() function in usage.c. There's
>warn(3) in BSD-style distros. It'd take a "great rename" to change it, but if
>someone with better C skills than I have could do that, my linker and I would
>appreciate it.
It was annoying to me, too, when I was doing some mergetool testing on
Mac OS X, so here's a fix.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Cc: "Randal L. Schwartz" <merlyn@stonehenge.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-bundle.c | patch | blob | history | |
fast-import.c | patch | blob | history | |
git-compat-util.h | patch | blob | history | |
revision.c | patch | blob | history | |
usage.c | patch | blob | history |
diff --git a/builtin-bundle.c b/builtin-bundle.c
index 0a9b73867f86a1ff33f7e2b2f458b02aacdd332d..d1635a0a6b009ecb6706084828abd0e3928f2b8d 100644 (file)
--- a/builtin-bundle.c
+++ b/builtin-bundle.c
if (buffer[len - 1] == '\n')
buffer[len - 1] = '\0';
if (get_sha1_hex(buffer + offset, sha1)) {
- warn("unrecognized header: %s", buffer);
+ warning("unrecognized header: %s", buffer);
continue;
}
delim = buffer[40 + offset];
* from getting output.
*/
if (!(e->item->flags & SHOWN)) {
- warn("ref '%s' is excluded by the rev-list options",
+ warning("ref '%s' is excluded by the rev-list options",
e->name);
continue;
}
diff --git a/fast-import.c b/fast-import.c
index bea12151c29af7f4242baaf80e12fd26eb550a45..cdd629d6bc547609daabab6c1f3b73939fddb7b9 100644 (file)
--- a/fast-import.c
+++ b/fast-import.c
if (!in_merge_bases(old_cmit, &new_cmit, 1)) {
unlock_ref(lock);
- warn("Not updating %s"
+ warning("Not updating %s"
" (new tip %s does not contain %s)",
b->name, sha1_to_hex(b->sha1), sha1_to_hex(old_sha1));
return -1;
diff --git a/git-compat-util.h b/git-compat-util.h
index 7534db1267bfa64a4a0cba80680fefc42177f0e8..139fc19108cab51eb23659868ef8600ff6b25795 100644 (file)
--- a/git-compat-util.h
+++ b/git-compat-util.h
extern void usage(const char *err) NORETURN;
extern void die(const char *err, ...) NORETURN __attribute__((format (printf, 1, 2)));
extern int error(const char *err, ...) __attribute__((format (printf, 1, 2)));
-extern void warn(const char *err, ...) __attribute__((format (printf, 1, 2)));
+extern void warning(const char *err, ...) __attribute__((format (printf, 1, 2)));
extern void set_usage_routine(void (*routine)(const char *err) NORETURN);
extern void set_die_routine(void (*routine)(const char *err, va_list params) NORETURN);
diff --git a/revision.c b/revision.c
index f23c1d52269576917ac2d8347b322805daa1bac5..486393cb0835ce70f685d665b916e1b67974f184 100644 (file)
--- a/revision.c
+++ b/revision.c
add_pending_object(cb->all_revs, o, "");
}
else if (!cb->warned_bad_reflog) {
- warn("reflog of '%s' references pruned commits",
+ warning("reflog of '%s' references pruned commits",
cb->name_for_errormsg);
cb->warned_bad_reflog = 1;
}