Commit Graph

10 Commits

Author SHA1 Message Date
matt335672 d11617adbe Remove dependency on signal() function
Replaces uses of signal() with sigaction() which should be far
more portable.
2023-10-09 14:05:29 +01:00
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 ff24984cf3 os_calls: Add g_file_is_open() 2023-05-02 11:55:22 +01:00
matt335672 cf9e07d341 Add basic tests for cloexec and get_open_fds functions 2023-04-24 14:20:14 +01:00
matt335672 2c6419475c Add basic tests for os_calls routines 2023-01-30 14:31:16 +00:00
matt335672 3146e624c4 Fix problems with check 0.15.2 (F36) 2022-01-19 11:08:13 +00:00
Koichiro IWAO ab558213b7 tests: skip some tests until g_file_get_size() fixed 2021-12-10 17:08:44 +09:00
Koichiro IWAO a57d8491c0 tests: add g_file_get_size() tests for files larger than 2GiB 2021-12-10 16:24:34 +09:00
Koichiro IWAO c24b6d95dd tests: create sparse file for g_file_get_size() tests 2021-12-10 16:24:34 +09:00
Koichiro IWAO 8e4ea49532 tests: add test on g_file_get_size() 2021-12-10 16:24:34 +09:00