comparison dbutil.h @ 1596:60fceff95858

workaround memory sanitizer FD_ZERO false positives
author Matt Johnston <matt@ucc.asn.au>
date Tue, 06 Mar 2018 21:51:51 +0800
parents 5916af64acd4
children e11ed628708b
comparison
equal deleted inserted replaced
1595:4fe7cc9e45eb 1596:60fceff95858
86 86
87 char * expand_homedir_path(const char *inpath); 87 char * expand_homedir_path(const char *inpath);
88 88
89 void fsync_parent_dir(const char* fn); 89 void fsync_parent_dir(const char* fn);
90 90
91 #if DROPBEAR_MSAN
92 /* FD_ZERO seems to leave some memory uninitialized. clear it to avoid false positives */
93 #define DROPBEAR_FD_ZERO(fds) do { memset((fds), 0x0, sizeof(fd_set)); FD_ZERO(fds); } while(0)
94 #else
95 #define DROPBEAR_FD_ZERO(fds) FD_ZERO(fds)
96 #endif
97
91 #endif /* DROPBEAR_DBUTIL_H_ */ 98 #endif /* DROPBEAR_DBUTIL_H_ */