Merge branch 'main' of https://git.olympuslab.net/Uni/djumbai
This commit is contained in:
commit
1b7e95c249
2 changed files with 2 additions and 2 deletions
|
@ -10,7 +10,7 @@
|
||||||
int main() {
|
int main() {
|
||||||
const char *message_queue_path = "/djumbai/fifos/message_queue";
|
const char *message_queue_path = "/djumbai/fifos/message_queue";
|
||||||
|
|
||||||
if (access(message_queue_path, F_OK) != -1) {
|
if (faccessat(AT_FDCWD,message_queue_path, F_OK,AT_EACCESS) != -1) {
|
||||||
// FIFO exists, delete it
|
// FIFO exists, delete it
|
||||||
if (unlink(message_queue_path) == -1) {
|
if (unlink(message_queue_path) == -1) {
|
||||||
perror("unlink");
|
perror("unlink");
|
||||||
|
|
|
@ -16,7 +16,7 @@ int main() {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
const char *send_fifo_path = "fifos/send_fifo";
|
const char *send_fifo_path = "fifos/send_fifo";
|
||||||
if (access(send_fifo_path, F_OK) != -1) {
|
if (faccessat(AT_FDCWD,send_fifo_path, F_OK,AT_EACCESS) != -1) {
|
||||||
// FIFO exists, delete it
|
// FIFO exists, delete it
|
||||||
if (unlink(send_fifo_path) == -1) {
|
if (unlink(send_fifo_path) == -1) {
|
||||||
perror("unlink");
|
perror("unlink");
|
||||||
|
|
Loading…
Reference in a new issue