Re: [PATCH] fixed return value check of sysoncf in get_name_from_passwd_file / get_username_from_passwd_file

2011-05-26 Thread Carl Worth
On Wed, 25 May 2011 14:27:55 +0200, Matthias Guedemann wrote: > > When trying to port notmuch to DragonFlyBSD I found it core dumped > immediately. The reason was that the "sysconf(_SC_GETPW_R_SIZE_MAX)" > call returned -1 which is used for talloc memory allocation. The check > was there but was

[PATCH] fixed return value check of sysoncf in get_name_from_passwd_file / get_username_from_passwd_file

2011-05-26 Thread Carl Worth
On Wed, 25 May 2011 14:27:55 +0200, Matthias Guedemann wrote: > > When trying to port notmuch to DragonFlyBSD I found it core dumped > immediately. The reason was that the "sysconf(_SC_GETPW_R_SIZE_MAX)" > call returned -1 which is used for talloc memory allocation. The check > was there but was

[PATCH] fixed return value check of sysoncf in get_name_from_passwd_file / get_username_from_passwd_file

2011-05-25 Thread Matthias Guedemann
When trying to port notmuch to DragonFlyBSD I found it core dumped immediately. The reason was that the "sysconf(_SC_GETPW_R_SIZE_MAX)" call returned -1 which is used for talloc memory allocation. The check was there but was done _after_ the allocation, the attached patch fixes this. regards Matt

[PATCH] fixed return value check of sysoncf in get_name_from_passwd_file / get_username_from_passwd_file

2011-05-25 Thread Matthias Guedemann
When trying to port notmuch to DragonFlyBSD I found it core dumped immediately. The reason was that the "sysconf(_SC_GETPW_R_SIZE_MAX)" call returned -1 which is used for talloc memory allocation. The check was there but was done _after_ the allocation, the attached patch fixes this. regards Matt