[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r103240: * md5.c (md5_process_bytes):
From: |
Paul Eggert |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r103240: * md5.c (md5_process_bytes): Use sizeof, not __alignof__. |
Date: |
Sat, 12 Feb 2011 14:36:22 -0800 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 103240
committer: Paul Eggert <address@hidden>
branch nick: trunk
timestamp: Sat 2011-02-12 14:36:22 -0800
message:
* md5.c (md5_process_bytes): Use sizeof, not __alignof__.
The difference doesn't matter here, in practice, and sizeof is
more portable to non-GCC compilers. Also, this makes the code
match the already-existing comment.
modified:
src/ChangeLog
src/md5.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2011-02-12 18:53:24 +0000
+++ b/src/ChangeLog 2011-02-12 22:36:22 +0000
@@ -1,3 +1,10 @@
+2011-02-12 Paul Eggert <address@hidden>
+
+ * md5.c (md5_process_bytes): Use sizeof, not __alignof__.
+ The difference doesn't matter here, in practice, and sizeof is
+ more portable to non-GCC compilers. Also, this makes the code
+ match the already-existing comment.
+
2011-02-12 Andreas Schwab <address@hidden>
* process.c (create_process): Reset SIGPIPE handler in the child.
=== modified file 'src/md5.c'
--- a/src/md5.c 2011-01-15 23:16:57 +0000
+++ b/src/md5.c 2011-02-12 22:36:22 +0000
@@ -216,7 +216,7 @@
size_t add = 128 - left_over > len ? len : 128 - left_over;
/* Only put full words in the buffer. */
- add -= add % __alignof__ (md5_uint32);
+ add -= add % sizeof (md5_uint32);
memcpy (&ctx->buffer[left_over], buffer, add);
ctx->buflen += add;
@@ -427,4 +427,3 @@
ctx->C = C;
ctx->D = D;
}
-
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r103240: * md5.c (md5_process_bytes): Use sizeof, not __alignof__.,
Paul Eggert <=