mirror of
https://github.com/samba-team/samba.git
synced 2025-01-06 13:18:07 +03:00
s4:ntvfs: Do not free eadb before we printed an error
Found by GCC 9.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13937
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit 6da032df54
)
This commit is contained in:
parent
541a98bc84
commit
9fda18d770
@ -123,7 +123,6 @@ static void pvfs_setup_options(struct pvfs_state *pvfs)
|
||||
pvfs, eadb, 50000,
|
||||
lpcfg_tdb_flags(pvfs->ntvfs->ctx->lp_ctx, TDB_DEFAULT),
|
||||
O_RDWR|O_CREAT, 0600);
|
||||
TALLOC_FREE(eadb);
|
||||
if (pvfs->ea_db != NULL) {
|
||||
pvfs->flags |= PVFS_FLAG_XATTR_ENABLE;
|
||||
} else {
|
||||
@ -131,6 +130,7 @@ static void pvfs_setup_options(struct pvfs_state *pvfs)
|
||||
eadb, strerror(errno)));
|
||||
pvfs->flags &= ~PVFS_FLAG_XATTR_ENABLE;
|
||||
}
|
||||
TALLOC_FREE(eadb);
|
||||
}
|
||||
|
||||
if (pvfs->flags & PVFS_FLAG_XATTR_ENABLE) {
|
||||
|
Loading…
Reference in New Issue
Block a user