Opened 16 years ago

Closed 16 years ago

#565 closed defect (fixed)

Call WSACleanup() when pj_shutdown() is called on Windows

Reported by: bennylp Owned by: bennylp
Priority: normal Milestone: release-1.0-rc1
Component: pjlib Version: trunk
Keywords: Cc:
Backport to 1.x milestone: Backported:

Description

Previously we disabled WSACleanup() because this may inadvertently cause application sockets to be closed. However without this call, we may leak some handles when application exits (some internal Windows Socket handles).

Now if application wants to work on sockets after pj_shutdown() is called, it must call WSAStartup() itself when the application is starting and WSACleanup() when application is quitting. This is possible since WSAStartup()/WSACleanup() may called multiple times and only the last WSACleanup() will cleanup Windows Socket.

Change History (1)

comment:1 Changed 16 years ago by bennylp

  • Resolution set to fixed
  • Status changed from new to closed

Done in r2132

Note: See TracTickets for help on using tickets.