Important bugfix for ntfs_mbstoucs_libntfscompat: We reallocated too little memory.

edge.strict_endians
Erik Larsson 2010-12-09 12:15:50 +01:00
parent 9c581432cb
commit e81fd0ee2a
1 changed files with 2 additions and 2 deletions

View File

@ -131,8 +131,8 @@ static __inline__ int ntfs_mbstoucs_libntfscompat(const char *ins,
/* Doing a realloc instead of reusing tmpstr
* because it emulates libntfs's mbstoucs more
* closely. */
ntfschar *re_outs =
realloc(*outs, tmpstr_len + 1);
ntfschar *re_outs = realloc(*outs,
sizeof(ntfschar)*(tmpstr_len + 1));
if(!re_outs)
tmpstr_len = -1;
else