diff options
| author | Philipp Stephani | 2020-08-02 16:05:44 +0200 |
|---|---|---|
| committer | Philipp Stephani | 2020-08-02 16:06:41 +0200 |
| commit | 2e9d1f4d44036e7c0605cfeac091368e013e3ed9 (patch) | |
| tree | 1ae7db9a7e531df4057803a2ab7c3b9d5c4e60f2 /src/alloc.c | |
| parent | e6eb554b95327549992c3684910921db9181ffb6 (diff) | |
| download | emacs-2e9d1f4d44036e7c0605cfeac091368e013e3ed9.tar.gz emacs-2e9d1f4d44036e7c0605cfeac091368e013e3ed9.zip | |
* src/alloc.c (mark_maybe_object): Avoid signed integer overflow
Diffstat (limited to 'src/alloc.c')
| -rw-r--r-- | src/alloc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/alloc.c b/src/alloc.c index da11426075b..5220ef84783 100644 --- a/src/alloc.c +++ b/src/alloc.c | |||
| @@ -4652,7 +4652,8 @@ mark_maybe_object (Lisp_Object obj) | |||
| 4652 | #else | 4652 | #else |
| 4653 | (void) overflow; | 4653 | (void) overflow; |
| 4654 | #endif | 4654 | #endif |
| 4655 | void *po = (char *) ((intptr_t) (char *) XLP (obj) + offset); | 4655 | INT_ADD_WRAPV (offset, (intptr_t) (char *) XLP (obj), &offset); |
| 4656 | void *po = (char *) offset; | ||
| 4656 | 4657 | ||
| 4657 | /* If the pointer is in the dump image and the dump has a record | 4658 | /* If the pointer is in the dump image and the dump has a record |
| 4658 | of the object starting at the place where the pointer points, we | 4659 | of the object starting at the place where the pointer points, we |