Commit Graph

7 Commits

Author SHA1 Message Date
Daniel Richard G
1c0c923ad1 Split g_file_open() into _ro() and _rw() variants
Rename g_file_open() to g_file_open_rw(), and add a new g_file_open_ro()
call that wraps the common g_file_open_ex(file, 1, 0, 0, 0) idiom. This
will make the file access mode more explicit in the code.

Change all calls to g_file_open() to the _ro() or _rw() variant as
appropriate, and replace g_file_open_ex(file, 1, 0, 0, 0) with the _ro()
call.

Lastly, add tests for the two new calls to test_os_calls.c (code
courteously provided by matt335672).
2023-05-15 17:38:31 -04:00
matt335672
7a190bf709 Add tests for libipm file descriptor calls 2023-01-30 14:31:16 +00:00
matt335672
02a3821f4d Remove libipm_msg_in_start()
The semantics of this call allowed it to be called more than once when
parsing a message to restart a parse. This is not likely to be
useful in practice, and it also makes reading file descriptors
more complicated. Consequently this function has been removed and
replaced with with libipm_msg_in_get_msgno()
2023-01-30 14:31:16 +00:00
matt335672
57bd1be5b1 Disable stdout buffering for LOG() when running tests
Normally the test runners run in 'forking mode'. When a lot of
messages are logged to stdout, the child process can still be writing
data when the parent writes 'ok' or 'not ok'. This can confuse
the tap-driver.sh process.
2023-01-30 14:31:16 +00:00
a1346054
7fe18cc1c0
fix typos 2022-09-03 02:01:48 +00:00
matt335672
3d91ba6a22 libipm: Make sockets always non-blocking 2022-03-15 10:45:00 +00:00
matt335672
6cf053c9df Add libipm test suite 2022-03-15 10:23:27 +00:00