#1110138 ltrace: wtb bitfield-enum decoding

Package:
ltrace
Source:
ltrace
Description:
Tracks runtime library calls in dynamically linked programs
Submitter:
наб
Date:
2025-07-31 19:31:01 UTC
Severity:
normal
Tags:
#1110138#5
Date:
2025-07-30 15:24:01 UTC
From:
To:
Dear Maintainer,

In a config like
	#include <sys/inotify.h>
	int inotify_init();
	int inotify_init1(octal);
	int inotify_add_watch(int, string, hex(int));
	int inotify_rm_watch(int, int);
the hex(int) field really wants to be an actual bitfielded named enum
like you actually use. This also features a few other times
(open family, inotify_init1, &c.), so a
	typedef inotify_watch = bitenum(IN_ACCESS=1, ..., IN_ALL_EVENTS=...);
would be useful.

Best,

#1110138#10
Date:
2025-07-31 19:29:32 UTC
From:
To:
memcpy(0x7ffeae63e888, ".", 1)                                                                            = 0x7ffeae63e888
inotify_add_watch(3, ".", IN_MOVED_TO|IN_CREATE|IN_DELETE_SELF|IN_MOVE_SELF|IN_ONLYDIR|IN_EXCL_UNLINK)    = 1
reallocarray(nil, 2, 8)                                                                                   = 0x55fb0d39a2e0