projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e6eb554
)
* src/alloc.c (mark_maybe_object): Avoid signed integer overflow
author
Philipp Stephani
<phst@google.com>
Sun, 2 Aug 2020 14:05:44 +0000
(16:05 +0200)
committer
Philipp Stephani
<phst@google.com>
Sun, 2 Aug 2020 14:06:41 +0000
(16:06 +0200)
src/alloc.c
patch
|
blob
|
history
diff --git
a/src/alloc.c
b/src/alloc.c
index da11426075bb3e0f180e082db2de602f1d4855d3..5220ef84783f293feb0b3a12cf266e9e3d70f52c 100644
(file)
--- a/
src/alloc.c
+++ b/
src/alloc.c
@@
-4652,7
+4652,8
@@
mark_maybe_object (Lisp_Object obj)
#else
(void) overflow;
#endif
- void *po = (char *) ((intptr_t) (char *) XLP (obj) + offset);
+ INT_ADD_WRAPV (offset, (intptr_t) (char *) XLP (obj), &offset);
+ void *po = (char *) offset;
/* If the pointer is in the dump image and the dump has a record
of the object starting at the place where the pointer points, we