[PATCH v2 1/2] fsck.c: Change the type of fsck_ident()'s first argument

2014-03-12 Thread Yuxuan Shui
Since fsck_ident doesn't change the content of **ident, the type of ident could be const char **. This change is required to rewrite fsck_commit() to use skip_prefix(). Signed-off-by: Yuxuan Shui yshu...@gmail.com --- fsck.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH v2 1/2] fsck.c: Change the type of fsck_ident()'s first argument

2014-03-12 Thread Jeff King
On Thu, Mar 13, 2014 at 02:51:29AM +0800, Yuxuan Shui wrote: Since fsck_ident doesn't change the content of **ident, the type of ident could be const char **. Unfortunately, const double-pointers in C are a bit tricky, and a pointer to char * cannot automatically be passed as a pointer to

Re: [PATCH v2 1/2] fsck.c: Change the type of fsck_ident()'s first argument

2014-03-12 Thread Yuxuan Shui
Hi, On Thu, Mar 13, 2014 at 4:22 AM, Jeff King p...@peff.net wrote: On Thu, Mar 13, 2014 at 02:51:29AM +0800, Yuxuan Shui wrote: Since fsck_ident doesn't change the content of **ident, the type of ident could be const char **. Unfortunately, const double-pointers in C are a bit tricky, and