1. 24 6月, 2006 1 次提交
    • P
      Customizable error handlers · 39a3f5ea
      Petr Baudis 提交于
      This patch makes the usage(), die() and error() handlers customizable.
      Nothing in the git code itself uses that but many other libgit users
      (like Git.pm) will.
      
      This is implemented using the mutator functions primarily because you
      cannot directly modifying global variables of libgit from a program that
      dlopen()ed it, apparently. But having functions for that is a better API
      anyway.
      Signed-off-by: NPetr Baudis <pasky@suse.cz>
      Signed-off-by: NJunio C Hamano <junkio@cox.net>
      39a3f5ea
  2. 10 3月, 2006 1 次提交
  3. 26 1月, 2006 1 次提交
  4. 08 1月, 2006 1 次提交
    • J
      [PATCH] Compilation: zero-length array declaration. · 8f1d2e6f
      Junio C Hamano 提交于
      ISO C99 (and GCC 3.x or later) lets you write a flexible array
      at the end of a structure, like this:
      
      	struct frotz {
      		int xyzzy;
      		char nitfol[]; /* more */
      	};
      
      GCC 2.95 and 2.96 let you to do this with "char nitfol[0]";
      unfortunately this is not allowed by ISO C90.
      
      This declares such construct like this:
      
      	struct frotz {
      		int xyzzy;
      		char nitfol[FLEX_ARRAY]; /* more */
      	};
      
      and git-compat-util.h defines FLEX_ARRAY to 0 for gcc 2.95 and
      empty for others.
      
      If you are using a C90 C compiler, you should be able
      to override this with CFLAGS=-DFLEX_ARRAY=1 from the
      command line of "make".
      Signed-off-by: NJunio C Hamano <junkio@cox.net>
      8f1d2e6f
  5. 29 12月, 2005 1 次提交
  6. 20 12月, 2005 1 次提交
  7. 15 12月, 2005 1 次提交
  8. 06 12月, 2005 1 次提交
    • J
      Clean up compatibility definitions. · 4050c0df
      Junio C Hamano 提交于
      This attempts to clean up the way various compatibility
      functions are defined and used.
      
       - A new header file, git-compat-util.h, is introduced.  This
         looks at various NO_XXX and does necessary function name
         replacements, equivalent of -Dstrcasestr=gitstrcasestr in the
         Makefile.
      
       - Those function name replacements are removed from the Makefile.
      
       - Common features such as usage(), die(), xmalloc() are moved
         from cache.h to git-compat-util.h; cache.h includes
         git-compat-util.h itself.
      Signed-off-by: NJunio C Hamano <junkio@cox.net>
      4050c0df