mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
loadparm: Fix CID 1273054 Improper use of negative value
Probably a "can't happen", but formally lpcfg_map_parameter can return -1 Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
This commit is contained in:
parent
d02840a3a4
commit
5d0a5c4216
@ -1338,6 +1338,9 @@ bool handle_smb_ports(struct loadparm_context *lp_ctx, struct loadparm_service *
|
||||
|
||||
if (parm_num == -1) {
|
||||
parm_num = lpcfg_map_parameter("smb ports");
|
||||
if (parm_num == -1) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if(!set_variable_helper(lp_ctx->globals->ctx, parm_num, ptr, "smb ports",
|
||||
|
Loading…
Reference in New Issue
Block a user