mirror of
https://github.com/samba-team/samba.git
synced 2025-03-09 08:58:35 +03:00
Fix Coverity ID 462
(This used to be commit 9cf1e16a9c3cade9cd905f719de07578b3a91b1e)
This commit is contained in:
parent
bc7a0a9198
commit
43554ded6d
@ -374,8 +374,10 @@ bool smb_io_relarraystr(const char *desc, RPC_BUFFER *buffer, int depth, uint16
|
||||
return False;
|
||||
|
||||
do {
|
||||
if (!smb_io_unistr(desc, &chaine, ps, depth))
|
||||
if (!smb_io_unistr(desc, &chaine, ps, depth)) {
|
||||
SAFE_FREE(chaine2);
|
||||
return False;
|
||||
}
|
||||
|
||||
l_chaine=str_len_uni(&chaine);
|
||||
|
||||
@ -402,10 +404,10 @@ bool smb_io_relarraystr(const char *desc, RPC_BUFFER *buffer, int depth, uint16
|
||||
{
|
||||
chaine2[l_chaine2] = '\0';
|
||||
*string=(uint16 *)TALLOC_MEMDUP(prs_get_mem_context(ps),chaine2,realloc_size);
|
||||
SAFE_FREE(chaine2);
|
||||
if (!*string) {
|
||||
return False;
|
||||
}
|
||||
SAFE_FREE(chaine2);
|
||||
}
|
||||
|
||||
if(!prs_set_offset(ps, old_offset))
|
||||
|
Loading…
x
Reference in New Issue
Block a user