libpwdgrp: fix a memory leak in getXXnam (we did not save address of string buf)
authorDenys Vlasenko <vda.linux@googlemail.com>
Sat, 3 Jan 2015 14:54:04 +0000 (15:54 +0100)
committerDenys Vlasenko <vda.linux@googlemail.com>
Sat, 3 Jan 2015 14:54:04 +0000 (15:54 +0100)
commit8d547aca75f8b096976a472714241acd4328be46
treecd7c4ba350c19f5369374302f7eb001e53cfe77e
parent31d6734457b9cafeeaa862750c2afa80aa67816c
libpwdgrp: fix a memory leak in getXXnam (we did not save address of string buf)

function                                             old     new   delta
convert_to_struct                                    261     269      +8
const_sp_db                                           20      24      +4
const_pw_db                                           20      24      +4
const_gr_db                                           20      24      +4
tokenize                                             144     147      +3
parse_common                                         185     188      +3
get_S                                                 82      85      +3
bb_internal_getpwent_r                               188     185      -3
gr_off                                                 4       -      -4
getXXnam                                             171     165      -6
pw_off                                                 7       -      -7
getgrouplist_internal                                237     229      -8
getXXnam_r                                           215     207      -8
sp_off                                                 9       -      -9
------------------------------------------------------------------------------
(add/remove: 0/3 grow/shrink: 7/4 up/down: 29/-45)            Total: -16 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
libpwdgrp/pwd_grp.c