Changeset 1952 for trunk/src/wsock32/new/wsock32.cpp
- Timestamp:
- Dec 3, 1999, 2:19:56 AM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wsock32/new/wsock32.cpp
r1951 r1952 1 /* $Id: wsock32.cpp,v 1.1 1 1999-12-02 21:35:29phaller Exp $ */1 /* $Id: wsock32.cpp,v 1.12 1999-12-03 01:19:56 phaller Exp $ */ 2 2 3 3 /* … … 47 47 #include <win32wnd.h> 48 48 49 49 50 #include "wsock32.h" 50 51 #include "relaywin.h" … … 64 65 65 66 static HWND hwndRelay = NULL; // handle to our relay window 67 68 69 /***************************************************************************** 70 * Prototypes * 71 *****************************************************************************/ 72 73 void __stdcall SetLastError(DWORD dwError); 66 74 67 75 … … 202 210 int,iError) 203 211 { 212 // according to the docs, WSASetLastError() is just a call-through 213 // to SetLastError() 204 214 WSASetLastError(iError); 215 SetLastError(iError); 205 216 } 206 217 … … 220 231 ODINFUNCTION0(int,OS2WSAGetLastError) 221 232 { 233 // according to the docs, WSASetLastError() is just a call-through 234 // to SetLastError(). However, what can be implemented here? 222 235 return WSAGetLastError(); 223 236 } … … 1167 1180 1168 1181 // add entry to list, we need to store both our temp buffer and the apps buffer 1169 ulNewID = RelayAlloc(hWnd, 1170 wMsg, 1171 FALSE, 1182 ulNewID = RelayAlloc(hWnd, 1183 wMsg, 1184 FALSE, 1172 1185 ASYNCREQUEST_GETSERVBYNAME, 1173 1186 buf); … … 1180 1193 buf, 1181 1194 buflen); 1182 1195 1183 1196 // if an error occurs, free the allocated relay entry 1184 1197 if (rc == SOCKET_ERROR) 1185 1198 RelayFree(ulNewID); 1186 1199 1187 return (rc); 1200 return (rc); 1188 1201 } 1189 1202 … … 1217 1230 1218 1231 // add entry to list, we need to store both our temp buffer and the apps buffer 1219 ulNewID = RelayAlloc(hWnd, 1220 wMsg, 1221 FALSE, 1232 ulNewID = RelayAlloc(hWnd, 1233 wMsg, 1234 FALSE, 1222 1235 ASYNCREQUEST_GETSERVBYPORT, 1223 1236 buf); … … 1230 1243 buf, 1231 1244 buflen); 1232 1245 1233 1246 // if an error occurs, free the allocated relay entry 1234 1247 if (rc == SOCKET_ERROR) 1235 1248 RelayFree(ulNewID); 1236 1237 return rc; 1249 1250 return rc; 1238 1251 } 1239 1252 … … 1266 1279 1267 1280 // add entry to list, we need to store both our temp buffer and the apps buffer 1268 ulNewID = RelayAlloc(hWnd, 1269 wMsg, 1270 FALSE, 1281 ulNewID = RelayAlloc(hWnd, 1282 wMsg, 1283 FALSE, 1271 1284 ASYNCREQUEST_GETPROTOBYNAME, 1272 1285 buf); … … 1278 1291 buf, 1279 1292 buflen); 1280 1293 1281 1294 // if an error occurs, free the allocated relay entry 1282 1295 if (rc == SOCKET_ERROR) 1283 1296 RelayFree(ulNewID); 1284 1297 1285 return (rc); 1298 return (rc); 1286 1299 } 1287 1300 … … 1314 1327 1315 1328 // add entry to list, we need to store both our temp buffer and the apps buffer 1316 ulNewID = RelayAlloc(hWnd, 1317 wMsg, 1318 FALSE, 1329 ulNewID = RelayAlloc(hWnd, 1330 wMsg, 1331 FALSE, 1319 1332 ASYNCREQUEST_GETPROTOBYNUMBER, 1320 1333 buf); … … 1326 1339 buf, 1327 1340 buflen); 1328 1341 1329 1342 // if an error occurs, free the allocated relay entry 1330 1343 if (rc == SOCKET_ERROR) 1331 1344 RelayFree(ulNewID); 1332 1345 1333 1346 return rc; 1334 1347 } … … 1362 1375 1363 1376 // add entry to list, we need to store both our temp buffer and the apps buffer 1364 ulNewID = RelayAlloc(hWnd, 1365 wMsg, 1366 FALSE, 1367 ASYNCREQUEST_GETHOSTBYNAME, 1377 ulNewID = RelayAlloc(hWnd, 1378 wMsg, 1379 FALSE, 1380 ASYNCREQUEST_GETHOSTBYNAME, 1368 1381 buf); 1369 1382 … … 1374 1387 buf, 1375 1388 buflen); 1376 1389 1377 1390 // if an error occurs, free the allocated relay entry 1378 1391 if (rc == SOCKET_ERROR) 1379 1392 RelayFree(ulNewID); 1380 1393 1381 1394 return rc; 1382 1395 } … … 1412 1425 1413 1426 // add entry to list, we need to store both our temp buffer and the apps buffer 1414 ulNewID = RelayAlloc(hWnd, 1415 wMsg, 1416 FALSE, 1427 ulNewID = RelayAlloc(hWnd, 1428 wMsg, 1429 FALSE, 1417 1430 ASYNCREQUEST_GETHOSTBYADDR, 1418 1431 buf); … … 1426 1439 buf, 1427 1440 buflen); 1428 1441 1429 1442 // if an error occurs, free the allocated relay entry 1430 1443 if (rc == SOCKET_ERROR) … … 1506 1519 else 1507 1520 // add entry to list 1508 ulNewID = RelayAlloc(hWnd, 1509 wMsg, 1521 ulNewID = RelayAlloc(hWnd, 1522 wMsg, 1510 1523 TRUE, 1511 1524 ASYNCREQUEST_SELECT);
Note:
See TracChangeset
for help on using the changeset viewer.