mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-29 13:28:10 +00:00
Only store the first log id received from the server.
Plugs a small memory leak in intercept mode if the log server sends the log ID again for sub-commands.
This commit is contained in:
parent
77ef8baa97
commit
0eb677b74a
@ -1553,8 +1553,10 @@ handle_log_id(char *id, struct client_closure *closure)
|
||||
debug_decl(handle_log_id, SUDOERS_DEBUG_UTIL);
|
||||
|
||||
sudo_debug_printf(SUDO_DEBUG_INFO, "%s: remote log ID: %s", __func__, id);
|
||||
if ((closure->iolog_id = strdup(id)) == NULL)
|
||||
sudo_fatal(NULL);
|
||||
if (closure->iolog_id != NULL) {
|
||||
if ((closure->iolog_id = strdup(id)) == NULL)
|
||||
sudo_fatal(NULL);
|
||||
}
|
||||
debug_return_bool(true);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user