projects
/
open-adventure.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
89829f4
)
Remove more unused code.
author
Eric S. Raymond
<esr@thyrsus.com>
Tue, 13 Jun 2017 13:42:18 +0000
(09:42 -0400)
committer
Eric S. Raymond
<esr@thyrsus.com>
Tue, 13 Jun 2017 13:42:18 +0000
(09:42 -0400)
advent.h
patch
|
blob
|
history
misc.c
patch
|
blob
|
history
diff --git
a/advent.h
b/advent.h
index c9fc43178b30fb3820c3028a5c8a86fbb07120f1..9c07cf390c18a62d7b58b589f6bf6407db725a6a 100644
(file)
--- a/
advent.h
+++ b/
advent.h
@@
-86,7
+86,6
@@
extern lcg_state lcgstate;
/* b is not needed for POSIX but harmless */
#define READ_MODE "rb"
#define WRITE_MODE "wb"
/* b is not needed for POSIX but harmless */
#define READ_MODE "rb"
#define WRITE_MODE "wb"
-extern void* xmalloc(size_t);
extern char* xstrdup(const char*);
extern void packed_to_token(long, char token[6]);
extern void newspeak(char*);
extern char* xstrdup(const char*);
extern void packed_to_token(long, char token[6]);
extern void newspeak(char*);
diff --git
a/misc.c
b/misc.c
index 16c6a78d6b30e02d599cba31bafb7caaf90c2a95..a58e461447c1f5701f45f56c5638082ba7ed10ee 100644
(file)
--- a/
misc.c
+++ b/
misc.c
@@
-10,17
+10,6
@@
#include "linenoise/linenoise.h"
#include "newdb.h"
#include "linenoise/linenoise.h"
#include "newdb.h"
-void* xmalloc(size_t size)
-{
- void* ptr = malloc(size);
- if (ptr == NULL)
- {
- fprintf(stderr, "Out of memory!\n");
- exit(EXIT_FAILURE);
- }
- return(ptr);
-}
-
char* xstrdup(const char* s)
{
char* ptr = strdup(s);
char* xstrdup(const char* s)
{
char* ptr = strdup(s);