gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r7447 - GNUnet/src/server


From: gnunet
Subject: [GNUnet-SVN] r7447 - GNUnet/src/server
Date: Fri, 18 Jul 2008 03:32:07 -0600 (MDT)

Author: holindho
Date: 2008-07-18 03:32:07 -0600 (Fri, 18 Jul 2008)
New Revision: 7447

Modified:
   GNUnet/src/server/handler.c
Log:
check alignment from the address not array position.


Modified: GNUnet/src/server/handler.c
===================================================================
--- GNUnet/src/server/handler.c 2008-07-18 03:53:27 UTC (rev 7446)
+++ GNUnet/src/server/handler.c 2008-07-18 09:32:07 UTC (rev 7447)
@@ -449,7 +449,7 @@
           return;
         }
 
-      if ((pos % ALIGN_REQUIRED) != 0)
+      if (((&msg[pos] - (char *)0) & (ALIGN_REQUIRED-1)) != 0)
        {
           /* correct misalignment; we allow messages to _not_ be a
              multiple of 4-bytes (if absolutely necessary; it should be





reply via email to

[Prev in Thread] Current Thread [Next in Thread]