forked from enlightenment/efl
Use eina_environment_tmp_get()
This commit is contained in:
parent
6e80c4aea1
commit
16063b8ab1
|
@ -774,11 +774,7 @@ _ecore_fps_debug_init(void)
|
|||
_ecore_fps_debug_init_count++;
|
||||
if (_ecore_fps_debug_init_count > 1) return;
|
||||
|
||||
#ifndef HAVE_EVIL
|
||||
tmp = "/tmp";
|
||||
#else
|
||||
tmp = evil_tmpdir_get ();
|
||||
#endif /* HAVE_EVIL */
|
||||
tmp = eina_environment_tmp_get();
|
||||
pid = (int)getpid();
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_fps_debug-%i", tmp, pid);
|
||||
_ecore_fps_debug_fd = open(buf, O_CREAT | O_TRUNC | O_RDWR, 0644);
|
||||
|
@ -829,16 +825,11 @@ _ecore_fps_debug_shutdown(void)
|
|||
if (_ecore_fps_debug_fd >= 0)
|
||||
{
|
||||
char buf[4096];
|
||||
const char *tmp;
|
||||
int pid;
|
||||
|
||||
#ifndef HAVE_EVIL
|
||||
tmp = "/tmp";
|
||||
#else
|
||||
tmp = (char *)evil_tmpdir_get ();
|
||||
#endif /* HAVE_EVIL */
|
||||
pid = (int)getpid();
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_fps_debug-%i", tmp, pid);
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_fps_debug-%i",
|
||||
eina_environment_tmp_get(), pid);
|
||||
unlink(buf);
|
||||
if (_ecore_fps_runtime_mmap)
|
||||
{
|
||||
|
|
|
@ -2966,17 +2966,12 @@ EAPI void
|
|||
_ecore_evas_fps_debug_init(void)
|
||||
{
|
||||
char buf[4096];
|
||||
const char *tmp;
|
||||
|
||||
_ecore_evas_fps_debug_init_count++;
|
||||
if (_ecore_evas_fps_debug_init_count > 1) return;
|
||||
|
||||
#ifndef HAVE_EVIL
|
||||
tmp = "/tmp";
|
||||
#else
|
||||
tmp = evil_tmpdir_get ();
|
||||
#endif /* HAVE_EVIL */
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_evas_fps_debug-%i", tmp, (int)getpid());
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_evas_fps_debug-%i",
|
||||
eina_environment_tmp_get(), (int)getpid());
|
||||
_ecore_evas_fps_debug_fd = open(buf, O_CREAT | O_TRUNC | O_RDWR, 0644);
|
||||
if (_ecore_evas_fps_debug_fd < 0)
|
||||
{
|
||||
|
@ -3026,7 +3021,8 @@ _ecore_evas_fps_debug_shutdown(void)
|
|||
{
|
||||
char buf[4096];
|
||||
|
||||
snprintf(buf, sizeof(buf), "/tmp/.ecore_evas_fps_debug-%i", (int)getpid());
|
||||
snprintf(buf, sizeof(buf), "%s/.ecore_evas_fps_debug-%i",
|
||||
eina_environment_tmp_get(), (int)getpid());
|
||||
unlink(buf);
|
||||
if (_ecore_evas_fps_rendertime_mmap)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue