projects
/
mmh
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Minor rearrangement so variables/functions used only if !HAVE_LIBLOCKFILE
[mmh]
/
uip
/
dropsbr.c
diff --git
a/uip/dropsbr.c
b/uip/dropsbr.c
index
7f432ea
..
2b3d020
100644
(file)
--- a/
uip/dropsbr.c
+++ b/
uip/dropsbr.c
@@
-10,17
+10,12
@@
*/
#include <h/nmh.h>
*/
#include <h/nmh.h>
+#include <h/utils.h>
-#ifndef MMDFONLY
-# include <h/mh.h>
-# include <h/dropsbr.h>
-# include <h/mts.h>
-# include <h/tws.h>
-#else
-# include "dropsbr.h"
-# include "strings.h"
-# include "mmdfonly.h"
-#endif
+#include <h/mh.h>
+#include <h/dropsbr.h>
+#include <h/mts.h>
+#include <h/tws.h>
#ifdef HAVE_ERRNO_H
# include <errno.h>
#ifdef HAVE_ERRNO_H
# include <errno.h>
@@
-224,14
+219,8
@@
mbx_read (FILE *fp, long pos, struct drop **drops, int noisy)
if (dp >= ep) {
register int curlen = dp - pp;
if (dp >= ep) {
register int curlen = dp - pp;
- cp = (struct drop *) realloc ((char *) pp,
+ cp = (struct drop *) mh_xrealloc ((char *) pp,
(size_t) (len += MAXFOLDER) * sizeof(*pp));
(size_t) (len += MAXFOLDER) * sizeof(*pp));
- if (cp == NULL) {
- if (noisy)
- admonish (NULL, "unable to allocate drop storage");
- free ((char *) pp);
- return 0;
- }
dp = cp + curlen, ep = (pp = cp) + len - 1;
}
}
dp = cp + curlen, ep = (pp = cp) + len - 1;
}
}