1
0
mirror of https://github.com/samba-team/samba.git synced 2025-09-14 21:44:19 +03:00

r19779: Fail properly on talloc_strdup failure

This commit is contained in:
Volker Lendecke
2006-11-19 10:54:57 +00:00
committed by Gerald (Jerry) Carter
parent cb7f4211b8
commit b57e446789

View File

@@ -369,9 +369,11 @@ WERROR regkey_open_internal( TALLOC_CTX *mem_ctx,
/* initialization */ /* initialization */
keyinfo->type = REG_KEY_GENERIC; keyinfo->type = REG_KEY_GENERIC;
keyinfo->name = talloc_strdup( keyinfo, path ); if (!(keyinfo->name = talloc_strdup(keyinfo, path))) {
result = WERR_NOMEM;
goto done;
}
/* Tag this as a Performance Counter Key */ /* Tag this as a Performance Counter Key */
if( StrnCaseCmp(path, KEY_HKPD, strlen(KEY_HKPD)) == 0 ) if( StrnCaseCmp(path, KEY_HKPD, strlen(KEY_HKPD)) == 0 )