aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin/edje/edje_cc.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2018-01-27 11:55:40 -0500
committerMike Blumenkrantz <zmike@osg.samsung.com>2018-01-27 11:56:31 -0500
commit18e392b50200cf30b0ca42121bff071c06b01251 (patch)
treec97d11b841b70141b277cab07c0881339a4e87e4 /src/bin/edje/edje_cc.c
parentefl_ui_focus_manager_calc: keep the entry for the redirect seperated (diff)
downloadefl-18e392b50200cf30b0ca42121bff071c06b01251.tar.gz
edje_cc: check HAVE_SYS_RESOURCE_H presence for rlimit usage
Diffstat (limited to '')
-rw-r--r--src/bin/edje/edje_cc.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/bin/edje/edje_cc.c b/src/bin/edje/edje_cc.c
index 9a67a55e45..428eacba0b 100644
--- a/src/bin/edje/edje_cc.c
+++ b/src/bin/edje/edje_cc.c
@@ -7,7 +7,10 @@
#include <limits.h>
#include <sys/stat.h>
#include <sys/time.h>
-#include <sys/resource.h>
+
+#ifdef HAVE_SYS_RESOURCE_H
+# include <sys/resource.h>
+#endif
#include "edje_cc.h"
int _edje_cc_log_dom = -1;
@@ -413,12 +416,16 @@ main(int argc, char **argv)
edje_file->efl_version.minor = 18;
edje_file->base_scale = FROM_INT(1);
+#ifdef HAVE_SYS_RESOURCE_H
{
struct rlimit lim;
if (getrlimit(RLIMIT_NOFILE, &lim))
fprintf(stderr, "error getting max open file limit: %s\n", strerror(errno));
max_open_files = lim.rlim_cur;
}
+#else
+ max_open_files = 1024;
+#endif
ecore_evas_init();
source_edd();