Module Name: src
Committed By: dholland
Date: Thu Feb 26 02:05:54 UTC 2015
Modified Files:
src/sys/sys: dirent.h
Log Message:
fix inadequate parens in macro (my fault originally)
To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/sys/sys/dirent.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/sys/dirent.h
diff -u src/sys/sys/dirent.h:1.28 src/sys/sys/dirent.h:1.29
--- src/sys/sys/dirent.h:1.28 Tue Sep 27 01:40:32 2011
+++ src/sys/sys/dirent.h Thu Feb 26 02:05:54 2015
@@ -1,4 +1,4 @@
-/* $NetBSD: dirent.h,v 1.28 2011/09/27 01:40:32 christos Exp $ */
+/* $NetBSD: dirent.h,v 1.29 2015/02/26 02:05:54 dholland Exp $ */
/*-
* Copyright (c) 1989, 1993
@@ -91,7 +91,7 @@ struct dirent {
* struct dirent
*/
#if __GNUC_PREREQ__(4, 0)
-#define _DIRENT_NAMEOFF(dp) __builtin_offsetof(__typeof__(*dp), d_name)
+#define _DIRENT_NAMEOFF(dp) __builtin_offsetof(__typeof__(*(dp)), d_name)
#else
#define _DIRENT_NAMEOFF(dp) \
((char *)(void *)&(dp)->d_name - (char *)(void *)dp)