Received: from sss.sss.pgh.pa.us (sss.pgh.pa.us [209.114.166.2]) by hub.org (8.9.3/8.9.3) with ESMTP id KAA51115 for ; Mon, 6 Sep 1999 10:56:31 -0400 (EDT) (envelope-from tgl@sss.pgh.pa.us) Received: from sss.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.sss.pgh.pa.us (8.9.1/8.9.1) with ESMTP id KAA17115; Mon, 6 Sep 1999 10:54:47 -0400 (EDT) To: "Hiroshi Inoue" cc: "Magnus Hagander" , "'David Giffin'" , "Ken J. Wright" , pgsql-interfaces@postgreSQL.org Subject: Re: [INTERFACES] Win32 interface In-reply-to: Your message of Mon, 6 Sep 1999 13:37:08 +0900 <000201bef821$7a95cf00$2801007e@cadzone.tpf.co.jp> Date: Mon, 06 Sep 1999 10:54:47 -0400 Message-ID: <17113.936629687@sss.pgh.pa.us> From: Tom Lane "Hiroshi Inoue" writes: >> ISTM there was some reason it wouldn't work, like maybe you can >> only call WSAStartup once per program, but I don't recall for sure. > We can call WSAStartup() more than once. However,there must be a > call to WSACleanup() for every successful call to WSAStartup() > made by a task. Only the final WSACleanup() for that task does the > actual cleanup. > > The simplest way may be to call WSAStartup() while connecting and > to call WSACleanup() while finishing(including error cases). That would be an easy change. Are these functions fast enough that calling them for every connect/disconnect cycle would be tolerable? regards, tom lane