summaryrefslogtreecommitdiff
path: root/src/fe-common/core
diff options
context:
space:
mode:
authorEdward Tomasz Napierala <trasz@FreeBSD.org>2017-08-09 11:06:36 +0100
committerEdward Tomasz Napierala <trasz@FreeBSD.org>2017-08-09 11:06:36 +0100
commit0c49a84ffb8d74506a13653183bfa1ef8ffd2554 (patch)
treeab01825f9790778ef0dd70bc4de87d76c91cd741 /src/fe-common/core
parent5db6caee0d17eb125d8c7f3090c325ffbee35920 (diff)
downloadirssi-0c49a84ffb8d74506a13653183bfa1ef8ffd2554.zip
Add back some ifdefs.
Signed-off-by: Edward Tomasz Napierala <trasz@FreeBSD.org>
Diffstat (limited to 'src/fe-common/core')
-rw-r--r--src/fe-common/core/fe-common-core.c2
-rw-r--r--src/fe-common/core/fe-log.c6
2 files changed, 8 insertions, 0 deletions
diff --git a/src/fe-common/core/fe-common-core.c b/src/fe-common/core/fe-common-core.c
index 67c9e20c..a3b7364c 100644
--- a/src/fe-common/core/fe-common-core.c
+++ b/src/fe-common/core/fe-common-core.c
@@ -32,7 +32,9 @@
#include "special-vars.h"
#include "fe-core-commands.h"
#include "fe-queries.h"
+#ifdef HAVE_CAPSICUM
#include "fe-capsicum.h"
+#endif
#include "hilight-text.h"
#include "command-history.h"
#include "completion.h"
diff --git a/src/fe-common/core/fe-log.c b/src/fe-common/core/fe-log.c
index 3d8910c9..0fed8642 100644
--- a/src/fe-common/core/fe-log.c
+++ b/src/fe-common/core/fe-log.c
@@ -30,7 +30,9 @@
#include "special-vars.h"
#include "settings.h"
#include "lib-config/iconfig.h"
+#ifdef HAVE_CAPSICUM
#include "capsicum.h"
+#endif
#include "fe-windows.h"
#include "window-items.h"
@@ -452,7 +454,11 @@ static void autolog_open(SERVER_REC *server, const char *server_tag,
log_item_add(log, LOG_ITEM_TARGET, target, server_tag);
dir = g_path_get_dirname(log->real_fname);
+#ifdef HAVE_CAPSICUM
capsicum_mkdir_with_parents_wrapper(dir, log_dir_create_mode);
+#else
+ g_mkdir_with_parents(dir, log_dir_create_mode);
+#endif
g_free(dir);
log->temp = TRUE;