aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2011-04-17 21:13:51 -0700
committerPaul Eggert2011-04-17 21:13:51 -0700
commitbfd1c7811d3661512b382906334ac959d332735b (patch)
tree7ec57551a9d6f60d53705cb5d410b56fc1e033d2 /src
parent83998b7a924b8362ec0c5650aa2c2911ac96cf70 (diff)
downloademacs-bfd1c7811d3661512b382906334ac959d332735b.tar.gz
emacs-bfd1c7811d3661512b382906334ac959d332735b.zip
* alloc.c (string_overrun_cookie): Now const. Use initializers that
don't formally overflow signed char, to avoid warnings.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog2
-rw-r--r--src/alloc.c4
2 files changed, 4 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 51e379c1280..d51052f0e3d 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -2,6 +2,8 @@
2 2
3 * alloc.c (BLOCK BYTES): Fix typo by changing "ablock" to "ablocks". 3 * alloc.c (BLOCK BYTES): Fix typo by changing "ablock" to "ablocks".
4 This doesn't fix a bug but makes the code clearer. 4 This doesn't fix a bug but makes the code clearer.
5 (string_overrun_cookie): Now const. Use initializers that
6 don't formally overflow signed char, to avoid warnings.
5 7
62011-04-17 Chong Yidong <cyd@stupidchicken.com> 82011-04-17 Chong Yidong <cyd@stupidchicken.com>
7 9
diff --git a/src/alloc.c b/src/alloc.c
index 8e0cf5d43e1..2029383dec8 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -1628,8 +1628,8 @@ static EMACS_INT total_string_size;
1628 presence of this cookie during GC. */ 1628 presence of this cookie during GC. */
1629 1629
1630#define GC_STRING_OVERRUN_COOKIE_SIZE 4 1630#define GC_STRING_OVERRUN_COOKIE_SIZE 4
1631static char string_overrun_cookie[GC_STRING_OVERRUN_COOKIE_SIZE] = 1631static char const string_overrun_cookie[GC_STRING_OVERRUN_COOKIE_SIZE] =
1632 { 0xde, 0xad, 0xbe, 0xef }; 1632 { '\xde', '\xad', '\xbe', '\xef' };
1633 1633
1634#else 1634#else
1635#define GC_STRING_OVERRUN_COOKIE_SIZE 0 1635#define GC_STRING_OVERRUN_COOKIE_SIZE 0