[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] Appease VC7. It has a strangely puritanical attitude about ...
- To: or-cvs@xxxxxxxxxxxxx
- Subject: [or-cvs] Appease VC7. It has a strangely puritanical attitude about ...
- From: nickm@xxxxxxxx (Nick Mathewson)
- Date: Wed, 27 Apr 2005 16:02:54 -0400 (EDT)
- Delivered-to: archiver@seul.org
- Delivered-to: or-cvs-outgoing@seul.org
- Delivered-to: or-cvs@seul.org
- Delivery-date: Wed, 27 Apr 2005 16:03:39 -0400
- Reply-to: or-dev@xxxxxxxxxxxxx
- Sender: owner-or-cvs@xxxxxxxxxxxxx
Update of /home/or/cvsroot/tor/src/or
In directory moria.mit.edu:/tmp/cvs-serv2149/src/or
Modified Files:
buffers.c
Log Message:
Appease VC7. It has a strangely puritanical attitude about what programmers are allowed to do a consenting void*.
Index: buffers.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/buffers.c,v
retrieving revision 1.142
retrieving revision 1.143
diff -u -d -r1.142 -r1.143
--- buffers.c 27 Apr 2005 19:40:31 -0000 1.142
+++ buffers.c 27 Apr 2005 20:02:52 -0000 1.143
@@ -23,8 +23,8 @@
*/
#define START_MAGIC 0x70370370u
#define END_MAGIC 0xA0B0C0D0u
-#define RAW_MEM(m) ((m)-4)
-#define GUARDED_MEM(m) ((m)+4)
+#define RAW_MEM(m) ((void*)(((char*)m)-4))
+#define GUARDED_MEM(m) ((void*)(((char*)m)+4))
#define ALLOC_LEN(ln) ((ln)+8)
#define SET_GUARDS(m, ln) \
do { set_uint32((m)-4,START_MAGIC); set_uint32((m)+ln,END_MAGIC); } while (0)