- else
- {
- // Ugly hard-code allowing execution of scripts on android without execution flag (such as on /sdcard)
- free(scriptname);
- len = xasprintf(&scriptname, "/system/bin/sh \"%s/%s\"", confbase, name);
- if(len < 0)
- {
- return false;
- }
- }
-#endif
+
+ // Custom scripts interpreter
+ if(get_config_string(cfg_interpreter, &interpreter)) {
+ // Force custom scripts interpreter allowing execution of scripts on android without execution flag (such as on /sdcard)
+ free(scriptname);
+ len = xasprintf(&scriptname, "%s \"%s/%s\"", interpreter, confbase, name);
+ free(interpreter);
+ if(len < 0)
+ return false;
+ }