Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 75801 | Differences between
and this patch

Collapse All | Expand All

(-)xpdf-2.02pl1/goo/gmem.c (-5 / +5 lines)
Lines 53-61 Link Here
53
53
54
#endif /* DEBUG_MEM */
54
#endif /* DEBUG_MEM */
55
55
56
void *gmalloc(int size) {
56
void *gmalloc(size_t size) {
57
#ifdef DEBUG_MEM
57
#ifdef DEBUG_MEM
58
  int size1;
58
  size_t size1;
59
  char *mem;
59
  char *mem;
60
  GMemHdr *hdr;
60
  GMemHdr *hdr;
61
  void *data;
61
  void *data;
Lines 94-104 Link Here
94
#endif
94
#endif
95
}
95
}
96
96
97
void *grealloc(void *p, int size) {
97
void *grealloc(void *p, size_t size) {
98
#ifdef DEBUG_MEM
98
#ifdef DEBUG_MEM
99
  GMemHdr *hdr;
99
  GMemHdr *hdr;
100
  void *q;
100
  void *q;
101
  int oldSize;
101
  size_t oldSize;
102
102
103
  if (size == 0) {
103
  if (size == 0) {
104
    if (p)
104
    if (p)
Lines 137-143 Link Here
137
137
138
void gfree(void *p) {
138
void gfree(void *p) {
139
#ifdef DEBUG_MEM
139
#ifdef DEBUG_MEM
140
  int size;
140
  size_t size;
141
  GMemHdr *hdr;
141
  GMemHdr *hdr;
142
  GMemHdr *prevHdr, *q;
142
  GMemHdr *prevHdr, *q;
143
  int lst;
143
  int lst;
(-)xpdf-2.02pl1/goo/gmem.h (-2 / +2 lines)
Lines 19-31 Link Here
19
 * Same as malloc, but prints error message and exits if malloc()
19
 * Same as malloc, but prints error message and exits if malloc()
20
 * returns NULL.
20
 * returns NULL.
21
 */
21
 */
22
extern void *gmalloc(int size);
22
extern void *gmalloc(size_t size);
23
23
24
/*
24
/*
25
 * Same as realloc, but prints error message and exits if realloc()
25
 * Same as realloc, but prints error message and exits if realloc()
26
 * returns NULL.  If <p> is NULL, calls malloc instead of realloc().
26
 * returns NULL.  If <p> is NULL, calls malloc instead of realloc().
27
 */
27
 */
28
extern void *grealloc(void *p, int size);
28
extern void *grealloc(void *p, size_t size);
29
29
30
/*
30
/*
31
 * Same as free, but checks for and ignores NULL pointers.
31
 * Same as free, but checks for and ignores NULL pointers.

Return to bug 75801