Hi, On Tue, 8 Jul 2008, Peter Harris wrote:
> diff --git a/compat/mingw.h b/compat/mingw.h > index 6bc049a..bf51f83 100644 > --- a/compat/mingw.h > +++ b/compat/mingw.h > @@ -194,6 +194,17 @@ sig_handler_t mingw_signal(int sig, sig_handler_t > handler); > #define signal mingw_signal > > /* > + * ANSI emulation wrappers > + */ > + > +int git_fputs(const char *str, FILE *stream); > +int git_printf(const char *format, ...) __attribute__((format (printf, 1, > 2))); > +int git_fprintf(FILE *stream, const char *format, ...) __attribute__((format > (printf, 2, 3))); Should these not rather be "mingw_*", or even better, "winansi_*"? > diff --git a/compat/winansi.c b/compat/winansi.c > new file mode 100644 > index 0000000..31deda3 > --- /dev/null > +++ b/compat/winansi.c > @@ -0,0 +1,335 @@ > +#include <windows.h> > +#include "../git-compat-util.h" > + > +/* > + Functions to be wrapped: > +*/ > +#undef printf > +#undef fprintf > +#undef fputs > + > +/* > + ANSI codes to implement: m, K > +*/ Does this mean that 'm' and 'K' are TODOs? (From your patch, it seems that 'm' is done already.) Anyway, if something is left to do, that should at least be described. If it is not left to do, it should be described, too... Other than that, looks quite good to me! Thanks, Dscho
