/[path-sandbox]/trunk/src/sandbox.c
Gentoo

Diff of /trunk/src/sandbox.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 262 Revision 263
128 buffer = (char *)malloc((len + 1) * sizeof(char)); 128 buffer = (char *)malloc((len + 1) * sizeof(char));
129 memset(buffer, 0, len + 1); 129 memset(buffer, 0, len + 1);
130 read(sandbox_log_file, buffer, len); 130 read(sandbox_log_file, buffer, len);
131 close(sandbox_log_file); 131 close(sandbox_log_file);
132 132
133 color = ((getenv("NOCOLOR") != NULL) ? 0 : 1); 133 color = ((is_env_on(ENV_NOCOLOR)) ? 0 : 1);
134 134
135 EERROR(color, 135 EERROR(color,
136 "--------------------------- ACCESS VIOLATION SUMMARY ---------------------------", 136 "--------------------------- ACCESS VIOLATION SUMMARY ---------------------------",
137 "\n"); 137 "\n");
138 EERROR(color, "LOG FILE = \"%s\"", "\n\n", sandbox_log); 138 EERROR(color, "LOG FILE = \"%s\"", "\n\n", sandbox_log);
335 sandbox_setenv(new_environ, ENV_SANDBOX_LIB, sandbox_info->sandbox_lib); 335 sandbox_setenv(new_environ, ENV_SANDBOX_LIB, sandbox_info->sandbox_lib);
336 sandbox_setenv(new_environ, ENV_SANDBOX_BASHRC, sandbox_info->sandbox_rc); 336 sandbox_setenv(new_environ, ENV_SANDBOX_BASHRC, sandbox_info->sandbox_rc);
337 sandbox_setenv(new_environ, ENV_SANDBOX_LOG, sandbox_info->sandbox_log); 337 sandbox_setenv(new_environ, ENV_SANDBOX_LOG, sandbox_info->sandbox_log);
338 sandbox_setenv(new_environ, ENV_SANDBOX_DEBUG_LOG, 338 sandbox_setenv(new_environ, ENV_SANDBOX_DEBUG_LOG,
339 sandbox_info->sandbox_debug_log); 339 sandbox_info->sandbox_debug_log);
340 /* Just set the these if not already set so that is_env_on() work */
341 if (!getenv(ENV_SANDBOX_VERBOSE))
342 sandbox_setenv(new_environ, ENV_SANDBOX_VERBOSE, "1");
343 if (!getenv(ENV_SANDBOX_DEBUG))
344 sandbox_setenv(new_environ, ENV_SANDBOX_DEBUG, "0");
345 if (!getenv(ENV_NOCOLOR))
346 sandbox_setenv(new_environ, ENV_NOCOLOR, "0");
340 /* If LD_PRELOAD was not set, set it here, else do it below */ 347 /* If LD_PRELOAD was not set, set it here, else do it below */
341 if (1 != have_ld_preload) 348 if (1 != have_ld_preload)
342 sandbox_setenv(new_environ, ENV_LD_PRELOAD, ld_preload_envvar); 349 sandbox_setenv(new_environ, ENV_LD_PRELOAD, ld_preload_envvar);
343 350
344 if (!getenv(ENV_SANDBOX_DENY)) 351 if (!getenv(ENV_SANDBOX_DENY))

Legend:
Removed from v.262  
changed lines
  Added in v.263

  ViewVC Help
Powered by ViewVC 1.1.20