Changeset 18424 in vbox for trunk/include/iprt
- Timestamp:
- Mar 28, 2009 1:40:40 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/string.h
r16323 r18424 72 72 #endif 73 73 74 /** 75 * Byte zero the specified object. 76 * 77 * This will use sizeof(Obj) to figure the size and will call memset, bzero 78 * or some compiler intrinsic to perform the actual zeroing. 79 * 80 * @param Obj The object to zero. Make sure to dereference pointers. 81 * 82 * @remarks Because the macro may use memset it has been placed in string.h 83 * instead of cdefs.h to avoid build issues because someone forgot 84 * to include this header. 85 * 86 * @ingroup grp_rt_cdefs 87 */ 88 #define RT_ZERO(Obj) RT_BZERO(&(Obj), sizeof(Obj)) 89 90 /** 91 * Byte zero the specified memory area. 92 * 93 * This will call memset, bzero or some compiler intrinsic to clear the 94 * specified bytes of memory. 95 * 96 * @param pv Pointer to the memory. 97 * @param cb The number of bytes to clear. Please, don't pass 0. 98 * 99 * @remarks Because the macro may use memset it has been placed in string.h 100 * instead of cdefs.h to avoid build issues because someone forgot 101 * to include this header. 102 * 103 * @ingroup grp_rt_cdefs 104 */ 105 #define RT_BZERO(pv, cb) do { memset((pv), 0, cb); } while (0) 106 74 107 75 108 /** @defgroup grp_rt_str RTStr - String Manipulation
Note:
See TracChangeset
for help on using the changeset viewer.