proj/intercept.c: Fix sigaction sa_mask value
This commit is contained in:
@@ -1419,7 +1419,7 @@ int sym(sigaction)(int sig, const struct sigaction *restrict act, struct sigacti
|
|||||||
if (sigismember(&act->sa_mask, i) != 1)
|
if (sigismember(&act->sa_mask, i) != 1)
|
||||||
continue;
|
continue;
|
||||||
if (maskstr[0] != 0) strcat(maskstr, ",");
|
if (maskstr[0] != 0) strcat(maskstr, ",");
|
||||||
strcat(maskstr, getsigstr(i));
|
sprintf(maskstr + strlen(maskstr), "%i:%s", i, getsigstr(i));
|
||||||
}
|
}
|
||||||
if (!verbosity) {
|
if (!verbosity) {
|
||||||
msg("sigaction(%i:%s, %p:{}, %p)" ret_str, sig, sigstr, act, oact, ret_data);
|
msg("sigaction(%i:%s, %p:{}, %p)" ret_str, sig, sigstr, act, oact, ret_data);
|
||||||
@@ -1462,7 +1462,7 @@ int sym(sigaction)(int sig, const struct sigaction *restrict act, struct sigacti
|
|||||||
if (sigismember(&oact->sa_mask, i) != 1)
|
if (sigismember(&oact->sa_mask, i) != 1)
|
||||||
continue;
|
continue;
|
||||||
if (maskstr[0] != 0) strcat(maskstr, ",");
|
if (maskstr[0] != 0) strcat(maskstr, ",");
|
||||||
strcat(maskstr, getsigstr(i));
|
sprintf(maskstr + strlen(maskstr), "%i:%s", i, getsigstr(i));
|
||||||
}
|
}
|
||||||
msg("return %i; errno %s; oact={sa_flags: 0x%x:%s, %s: %p, sa_mask: [%s]}", ret, strerrorname_np(errno), oact->sa_flags, flgstr, name, ptr, maskstr);
|
msg("return %i; errno %s; oact={sa_flags: 0x%x:%s, %s: %p, sa_mask: [%s]}", ret, strerrorname_np(errno), oact->sa_flags, flgstr, name, ptr, maskstr);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ class Flags(NamedTuple):
|
|||||||
flags: list[str]
|
flags: list[str]
|
||||||
|
|
||||||
StructTimeSpec = TypedDict('StructTimeSpec', {'tv_sec': int, 'tv_nsec': int})
|
StructTimeSpec = TypedDict('StructTimeSpec', {'tv_sec': int, 'tv_nsec': int})
|
||||||
StructSigAction = TypedDict('StructSigAction', {'sa_flags': Flags, 'sa_handler': NotRequired[Pointer], 'sa_sigaction': NotRequired[Pointer], 'sa_mask': list[str]})
|
StructSigAction = TypedDict('StructSigAction', {'sa_flags': Flags, 'sa_handler': NotRequired[Pointer], 'sa_sigaction': NotRequired[Pointer], 'sa_mask': list[Constant]})
|
||||||
StructSockAddr = TypedDict('StructSockAddr', {'sa_family': Constant, 'sa_data': NotRequired[bytes],
|
StructSockAddr = TypedDict('StructSockAddr', {'sa_family': Constant, 'sa_data': NotRequired[bytes],
|
||||||
'sun_path': NotRequired[bytes],
|
'sun_path': NotRequired[bytes],
|
||||||
'sin_addr': NotRequired[bytes], 'sin_port': NotRequired[int],
|
'sin_addr': NotRequired[bytes], 'sin_port': NotRequired[int],
|
||||||
|
|||||||
Reference in New Issue
Block a user