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
0ce958d0
Commit
0ce958d0
authored
Sep 28, 1993
by
Richard Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Include stdio.h.
(xmalloc): New function. From-SVN: r5520
parent
ae0d8288
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
0 deletions
+36
-0
gcc/bi-arity.c
+18
-0
gcc/bi-opname.c
+18
-0
No files found.
gcc/bi-arity.c
View file @
0ce958d0
...
...
@@ -18,6 +18,7 @@ along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#include <stdio.h>
#include "bi-defs.h"
int
...
...
@@ -54,3 +55,20 @@ main ()
}
return
0
;
}
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
char
*
xmalloc
(
nbytes
)
int
nbytes
;
{
char
*
tmp
=
(
char
*
)
malloc
(
nbytes
);
if
(
!
tmp
)
{
fprintf
(
stderr
,
"can't allocate %d bytes (out of virtual memory)
\n
"
,
nbytes
);
exit
(
1
);
}
return
tmp
;
}
gcc/bi-opname.c
View file @
0ce958d0
...
...
@@ -17,6 +17,7 @@ You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#include <stdio.h>
#include "bi-defs.h"
int
...
...
@@ -33,3 +34,20 @@ main()
printf
(
"
\"
%s%s
\"
,
\n
"
,
d
->
basename
,
v
->
name
);
return
0
;
}
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
char
*
xmalloc
(
nbytes
)
int
nbytes
;
{
char
*
tmp
=
(
char
*
)
malloc
(
nbytes
);
if
(
!
tmp
)
{
fprintf
(
stderr
,
"can't allocate %d bytes (out of virtual memory)
\n
"
,
nbytes
);
exit
(
1
);
}
return
tmp
;
}
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