Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
UDP broadcast message fails
#10
(08-17-2019, 04:35 AM)Boba TC Wrote: The last line (WSAIoctl() call) causes an AV no matter what. Note: both pointers in the call are 16-byte aligned otherwise the return is error 10014.

See https://stackoverflow.com/questions/861154/. Apparently Windows 10 has a known issue where sometimes Winsock does not like using buffers on the stack even if they are aligned properly. Try dynamically allocating them on the heap instead.

Also, why are you allocating a 32K buffer on the stack? The code you showed does not use or need it. You are just wasting the stack.

(08-17-2019, 04:35 AM)Boba TC Wrote: This happens on win10-64 regardless of compatibility settings. Neither MS compilers nor 3rd party ones exhibit this problem.

Have you compared the codegen between the various compilers for the same code to see what is different between them?

Reply


Messages In This Thread
UDP broadcast message fails - by Boba TC - 07-18-2019, 03:49 AM
RE: UDP broadcast message fails - by Boba TC - 07-18-2019, 05:51 PM
RE: UDP broadcast message fails - by rlebeau - 07-18-2019, 10:22 PM
RE: UDP broadcast message fails - by Boba TC - 07-19-2019, 02:26 AM
RE: UDP broadcast message fails - by rlebeau - 07-19-2019, 09:55 PM
RE: UDP broadcast message fails - by Boba TC - 07-20-2019, 02:08 AM
RE: UDP broadcast message fails - by Boba TC - 08-17-2019, 04:35 AM
RE: UDP broadcast message fails - by rlebeau - 08-17-2019, 07:22 AM
RE: UDP broadcast message fails - by Boba TC - 07-20-2019, 08:09 PM
RE: UDP broadcast message fails - by rlebeau - 07-23-2019, 09:35 PM
RE: UDP broadcast message fails - by Boba TC - 08-22-2019, 12:53 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)