From: Dana Jansens Date: Wed, 30 May 2007 01:01:24 +0000 (+0000) Subject: bug fix X-Git-Tag: release-2.0.2~158 X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=8fe32456d967700bd8b276addd3938b086649854;p=dana%2Fobconf.git bug fix --- diff --git a/src/theme.c b/src/theme.c index 2059eb1..6f080c8 100644 --- a/src/theme.c +++ b/src/theme.c @@ -223,9 +223,9 @@ static int gzopen_frontend(const char *path, int oflags, int mode) int fd; const char *gzflags; - if (oflags & O_RDONLY) + if ((oflags & O_ACCMODE) == O_RDONLY) gzflags = "rb"; - else if (oflags & O_WRONLY) + else if ((oflags & O_ACCMODE) == O_WRONLY) gzflags = "wb"; else g_assert_not_reached();