Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
6524f653
Commit
6524f653
authored
Apr 17, 1996
by
Doug Evans
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't include sys/file.h ifdef NO_SYS_FILE_H.
(choose_temp_base): Make tmp,usrtmp static locals. From-SVN: r11835
parent
1ad2a62d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
gcc/choose-temp.c
+3
-4
No files found.
gcc/choose-temp.c
View file @
6524f653
...
...
@@ -19,7 +19,7 @@ Boston, MA 02111-1307, USA. */
/* This file exports one function: choose_temp_base. */
#if
ndef _WIN32
#if
! defined (_WIN32) && ! defined (NO_SYS_FILE_H)
#include <sys/file.h>
/* May get R_OK, etc. on some systems. */
#endif
...
...
@@ -90,7 +90,8 @@ choose_temp_base ()
char
*
base
=
0
;
char
*
temp_filename
;
int
len
;
char
usrtmp
[
sizeof
(
"/usr/tmp"
)],
tmp
[
sizeof
(
"/tmp"
)];
static
char
tmp
[]
=
{
DIR_SEPARATOR
,
't'
,
'm'
,
'p'
,
0
};
static
char
usrtmp
[]
=
{
DIR_SEPARATOR
,
'u'
,
's'
,
'r'
,
DIR_SEPARATOR
,
't'
,
'm'
,
'p'
,
0
};
#ifndef MPW
base
=
try
(
getenv
(
"TMPDIR"
),
base
);
...
...
@@ -102,9 +103,7 @@ choose_temp_base ()
#endif
/* Try /usr/tmp, then /tmp. */
sprintf
(
usrtmp
,
"%cusr%ctmp"
,
DIR_SEPARATOR
,
DIR_SEPARATOR
);
base
=
try
(
usrtmp
,
base
);
sprintf
(
tmp
,
"%ctmp"
,
DIR_SEPARATOR
);
base
=
try
(
tmp
,
base
);
/* If all else fails, use the current directory! */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment