diff options
author | Timo Hirvonen <tihirvon@gmail.com> | 2006-02-26 17:13:46 +0200 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-02-26 15:06:45 -0800 |
commit | 962554c616e30991553c8497ed1e7c2a415fa84d (patch) | |
tree | 710390ca470a4a203635d3ce6f48bc426a99bfb3 | |
parent | contrib/git-svn: version 0.10.0 (diff) | |
download | tgif-962554c616e30991553c8497ed1e7c2a415fa84d.tar.xz |
Use setenv(), fix warnings
- Fix -Wundef -Wold-style-definition warnings
- Make pll_free() static
[jc: original patch by Timo had another unrelated bits:
- Use setenv() instead of putenv()
I'm postponing that part for now.]
Signed-off-by: Timo Hirvonen <tihirvon@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
-rw-r--r-- | cache.h | 2 | ||||
-rw-r--r-- | exec_cmd.c | 2 | ||||
-rw-r--r-- | fetch-pack.c | 2 | ||||
-rw-r--r-- | fsck-objects.c | 2 | ||||
-rw-r--r-- | pack-objects.c | 2 | ||||
-rw-r--r-- | pack-redundant.c | 4 |
6 files changed, 7 insertions, 7 deletions
@@ -10,7 +10,7 @@ #define deflateBound(c,s) ((s) + (((s) + 7) >> 3) + (((s) + 63) >> 6) + 11) #endif -#if defined(DT_UNKNOWN) && !NO_D_TYPE_IN_DIRENT +#if defined(DT_UNKNOWN) && !defined(NO_D_TYPE_IN_DIRENT) #define DTYPE(de) ((de)->d_type) #else #undef DT_UNKNOWN diff --git a/exec_cmd.c b/exec_cmd.c index 55af33bb7e..b5e59a9ae9 100644 --- a/exec_cmd.c +++ b/exec_cmd.c @@ -13,7 +13,7 @@ void git_set_exec_path(const char *exec_path) /* Returns the highest-priority, location to look for git programs. */ -const char *git_exec_path() +const char *git_exec_path(void) { const char *env; diff --git a/fetch-pack.c b/fetch-pack.c index 09738fee91..535de10660 100644 --- a/fetch-pack.c +++ b/fetch-pack.c @@ -82,7 +82,7 @@ static void mark_common(struct commit *commit, Get the next rev to send, ignoring the common. */ -static const unsigned char* get_rev() +static const unsigned char* get_rev(void) { struct commit *commit = NULL; diff --git a/fsck-objects.c b/fsck-objects.c index 6439d55126..4ddd67699c 100644 --- a/fsck-objects.c +++ b/fsck-objects.c @@ -20,7 +20,7 @@ static int check_strict = 0; static int keep_cache_objects = 0; static unsigned char head_sha1[20]; -#if NO_D_INO_IN_DIRENT +#ifdef NO_D_INO_IN_DIRENT #define SORT_DIRENT 0 #define DIRENT_SORT_HINT(de) 0 #else diff --git a/pack-objects.c b/pack-objects.c index 0287449b4c..21ee572f48 100644 --- a/pack-objects.c +++ b/pack-objects.c @@ -768,7 +768,7 @@ static int sha1_sort(const struct object_entry *a, const struct object_entry *b) return memcmp(a->sha1, b->sha1, 20); } -static struct object_entry **create_final_object_list() +static struct object_entry **create_final_object_list(void) { struct object_entry **list; int i, j; diff --git a/pack-redundant.c b/pack-redundant.c index 1869b38b72..cd81f5a66e 100644 --- a/pack-redundant.c +++ b/pack-redundant.c @@ -45,7 +45,7 @@ static inline void llist_item_put(struct llist_item *item) free_nodes = item; } -static inline struct llist_item *llist_item_get() +static inline struct llist_item *llist_item_get(void) { struct llist_item *new; if ( free_nodes ) { @@ -275,7 +275,7 @@ static void cmp_two_packs(struct pack_list *p1, struct pack_list *p2) } } -void pll_free(struct pll *l) +static void pll_free(struct pll *l) { struct pll *old; struct pack_list *opl; |