Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-gnome
Path: blob/main/mail/balsa/files/patch-libbalsa_mailbox_mbox.c
16149 views
1
--- libbalsa/mailbox_mbox.c.orig Tue Dec 27 14:54:34 2005
2
+++ libbalsa/mailbox_mbox.c Thu Dec 29 01:44:01 2005
3
@@ -26,6 +26,7 @@
4
5
#include <gmime/gmime-stream-fs.h>
6
7
+#include <sys/stat.h>
8
#include <stdlib.h>
9
#include <unistd.h>
10
#include <fcntl.h>
11
@@ -214,7 +215,7 @@ lbm_mbox_check_files(const gchar * path,
12
} else if (create) {
13
gint fd;
14
15
- if ((fd = creat(path, S_IRUSR | S_IWUSR)) == -1) {
16
+ if ((fd = open(path, O_CREAT | O_TRUNC | O_WRONLY, S_IRUSR | S_IWUSR)) == -1) {
17
g_warning("An error:\n%s\n occurred while trying to "
18
"create the mailbox \"%s\"\n",
19
strerror(errno), path);
20
21