Changeset 50566 in vbox for trunk/src/VBox/Additions/common/VBoxService
- Timestamp:
- Feb 24, 2014 11:13:52 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxService/VBoxServiceVMInfo.cpp
r50565 r50566 1157 1157 * interface will get multiple entries for one physical interface. 1158 1158 */ 1159 # ifdef RT_OS_OS21159 # ifdef RT_OS_OS2 1160 1160 struct ifreq *pPrevLinkAddr = NULL; 1161 # endif1161 # endif 1162 1162 struct ifreq *pCur = IfConf.ifc_req; 1163 1163 size_t cbLeft = IfConf.ifc_len; … … 1166 1166 /* Figure the size of the current request. */ 1167 1167 size_t const cbCur = RT_OFFSETOF(struct ifreq, ifr_addr) 1168 # ifdef SA_LEN 1169 + RT_MAX(sizeof(struct sockaddr), SA_LEN(pCur->ifr_addr)); 1170 # else 1168 1171 + RT_MAX(sizeof(struct sockaddr), pCur->ifr_addr.sa_len); 1172 # endif 1169 1173 AssertBreak(cbCur <= cbLeft); 1170 1174 1171 # ifdef RT_OS_OS21175 # ifdef RT_OS_OS2 1172 1176 /* On OS/2 we get the MAC address in the AF_LINK that the BSD 4.4 stack 1173 1177 emits. We boldly ASSUME these always comes first. */ … … 1175 1179 && ((struct sockaddr_dl *)&pCur->ifr_addr)->sdl_alen == 6) 1176 1180 pPrevLinkAddr = pCur; 1177 # endif1181 # endif 1178 1182 1179 1183 /* Skip it if it's not the kind of address we're looking for. */
Note:
See TracChangeset
for help on using the changeset viewer.