forked from enlightenment/enlightenment
efm - make some comment notes for exec verify
This commit is contained in:
parent
3fdd7d3118
commit
7062c0fa4c
|
@ -1521,6 +1521,7 @@ _e_fwin_file_exec(E_Fwin_Page *page,
|
||||||
|
|
||||||
case E_FWIN_EXEC_DIRECT:
|
case E_FWIN_EXEC_DIRECT:
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", e_fm2_real_path_get(fwin->cur_page->fm_obj), ici->file);
|
snprintf(buf, sizeof(buf), "%s/%s", e_fm2_real_path_get(fwin->cur_page->fm_obj), ici->file);
|
||||||
|
// XXX: exec verify buf
|
||||||
if (fwin->win)
|
if (fwin->win)
|
||||||
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
||||||
else if (fwin->zone)
|
else if (fwin->zone)
|
||||||
|
@ -1529,6 +1530,7 @@ _e_fwin_file_exec(E_Fwin_Page *page,
|
||||||
|
|
||||||
case E_FWIN_EXEC_SH:
|
case E_FWIN_EXEC_SH:
|
||||||
snprintf(buf, sizeof(buf), "/bin/sh %s", e_util_filename_escape(ici->file));
|
snprintf(buf, sizeof(buf), "/bin/sh %s", e_util_filename_escape(ici->file));
|
||||||
|
// XXX: exec verify buf
|
||||||
if (fwin->win)
|
if (fwin->win)
|
||||||
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
||||||
else if (fwin->zone)
|
else if (fwin->zone)
|
||||||
|
@ -1537,6 +1539,7 @@ _e_fwin_file_exec(E_Fwin_Page *page,
|
||||||
|
|
||||||
case E_FWIN_EXEC_TERMINAL_DIRECT:
|
case E_FWIN_EXEC_TERMINAL_DIRECT:
|
||||||
snprintf(buf, sizeof(buf), "%s %s", e_config->exebuf_term_cmd, e_util_filename_escape(ici->file));
|
snprintf(buf, sizeof(buf), "%s %s", e_config->exebuf_term_cmd, e_util_filename_escape(ici->file));
|
||||||
|
// XXX: exec verify buf
|
||||||
if (fwin->win)
|
if (fwin->win)
|
||||||
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
||||||
else if (fwin->zone)
|
else if (fwin->zone)
|
||||||
|
@ -1545,6 +1548,7 @@ _e_fwin_file_exec(E_Fwin_Page *page,
|
||||||
|
|
||||||
case E_FWIN_EXEC_TERMINAL_SH:
|
case E_FWIN_EXEC_TERMINAL_SH:
|
||||||
snprintf(buf, sizeof(buf), "%s /bin/sh %s", e_config->exebuf_term_cmd, e_util_filename_escape(ici->file));
|
snprintf(buf, sizeof(buf), "%s /bin/sh %s", e_config->exebuf_term_cmd, e_util_filename_escape(ici->file));
|
||||||
|
// XXX: exec verify buf
|
||||||
if (fwin->win)
|
if (fwin->win)
|
||||||
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
e_exec(e_comp_object_util_zone_get(fwin->win), NULL, buf, NULL, "fwin");
|
||||||
else if (fwin->zone)
|
else if (fwin->zone)
|
||||||
|
@ -1553,6 +1557,7 @@ _e_fwin_file_exec(E_Fwin_Page *page,
|
||||||
|
|
||||||
case E_FWIN_EXEC_DESKTOP:
|
case E_FWIN_EXEC_DESKTOP:
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", e_fm2_real_path_get(page->fm_obj), ici->file);
|
snprintf(buf, sizeof(buf), "%s/%s", e_fm2_real_path_get(page->fm_obj), ici->file);
|
||||||
|
// XXX: exec verify buf
|
||||||
desktop = efreet_desktop_new(buf);
|
desktop = efreet_desktop_new(buf);
|
||||||
if (desktop)
|
if (desktop)
|
||||||
{
|
{
|
||||||
|
|
|
@ -244,7 +244,7 @@ _e_fileman_dbus_daemon_open_file_cb(const Eldbus_Service_Interface *iface EINA_U
|
||||||
errmsg = "couldn't open desktop file";
|
errmsg = "couldn't open desktop file";
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
// XXX: exec verify real_file
|
||||||
e_exec(zone, desktop, NULL, NULL, NULL);
|
e_exec(zone, desktop, NULL, NULL, NULL);
|
||||||
efreet_desktop_free(desktop);
|
efreet_desktop_free(desktop);
|
||||||
goto end;
|
goto end;
|
||||||
|
@ -252,11 +252,13 @@ _e_fileman_dbus_daemon_open_file_cb(const Eldbus_Service_Interface *iface EINA_U
|
||||||
else if ((strcmp(mime, "application/x-executable") == 0) ||
|
else if ((strcmp(mime, "application/x-executable") == 0) ||
|
||||||
ecore_file_can_exec(param_file))
|
ecore_file_can_exec(param_file))
|
||||||
{
|
{
|
||||||
|
// XXX: exec verify param_file
|
||||||
e_exec(zone, NULL, param_file, NULL, NULL);
|
e_exec(zone, NULL, param_file, NULL, NULL);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
else if (_mime_shell_script_check(mime))
|
else if (_mime_shell_script_check(mime))
|
||||||
{
|
{
|
||||||
|
// XXX: exec verify param_file
|
||||||
Eina_Strbuf *b = eina_strbuf_new();
|
Eina_Strbuf *b = eina_strbuf_new();
|
||||||
const char *shell = getenv("SHELL");
|
const char *shell = getenv("SHELL");
|
||||||
if (!shell)
|
if (!shell)
|
||||||
|
|
Loading…
Reference in New Issue