mirror of
https://github.com/moparisthebest/hexchat
synced 2024-11-21 16:55:02 -05:00
Clean up some ifdefs
Thankfully somebody already made a define for this, they just never used it...
This commit is contained in:
parent
97bf0de016
commit
a5584c6b57
@ -176,11 +176,7 @@ scrollback_shrink (session *sess)
|
||||
p++;
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
fh = g_open (file, O_CREAT | O_TRUNC | O_APPEND | O_WRONLY | _O_BINARY, 0644);
|
||||
#else
|
||||
fh = g_open (file, O_CREAT | O_TRUNC | O_APPEND | O_WRONLY, 0644);
|
||||
#endif
|
||||
fh = g_open (file, O_CREAT | O_TRUNC | O_APPEND | O_WRONLY | OFLAGS, 0644);
|
||||
g_free (file);
|
||||
if (fh == -1)
|
||||
{
|
||||
@ -236,7 +232,7 @@ scrollback_save (session *sess, char *text)
|
||||
if ((buf = scrollback_get_filename (sess)) == NULL)
|
||||
return;
|
||||
|
||||
sess->scrollfd = g_open (buf, O_CREAT | O_APPEND | O_WRONLY, 0644);
|
||||
sess->scrollfd = g_open (buf, O_CREAT | O_APPEND | O_WRONLY | OFLAGS, 0644);
|
||||
g_free (buf);
|
||||
if (sess->scrollfd == -1)
|
||||
return;
|
||||
@ -595,11 +591,7 @@ log_open_file (char *servname, char *channame, char *netname)
|
||||
if (!file)
|
||||
return -1;
|
||||
|
||||
#ifdef WIN32
|
||||
fd = g_open (file, O_CREAT | O_APPEND | O_WRONLY | _O_BINARY, S_IREAD|S_IWRITE);
|
||||
#else
|
||||
fd = g_open (file, O_CREAT | O_APPEND | O_WRONLY, 0644);
|
||||
#endif
|
||||
fd = g_open (file, O_CREAT | O_APPEND | O_WRONLY | OFLAGS, 0644);
|
||||
g_free (file);
|
||||
|
||||
if (fd == -1)
|
||||
|
Loading…
Reference in New Issue
Block a user