Branch: Tag:

2014-05-17

2014-05-17 11:43:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

SSL.sslfile: Changed client/server selection API.

Client and server operation is now selected by calling either
connect() (client-side) or accept() (server-side) after creating
the SSL.sslfile object.

Blocking handshaking mode is selected by calling set_blocking()
before either of the above.

211: Inside #if constant(SSL.sslfile)
   void create(Stdio.File stream, SSL.Context ctx)    { rawstream=stream;    std::create(stream,ctx,1,1); +  std::set_blocking(); +  if (!std::connect()) { +  error("Secure connection failed.\n"); +  }    pg::create();    }   }