mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 08:41:03 +00:00
Fix looping session startup
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@38386 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
1fdfbc8b46
commit
89ae58eb4c
2 changed files with 14 additions and 0 deletions
|
@ -1001,12 +1001,14 @@ GSTLSHandlePush(gnutls_transport_ptr_t handle, const void *buffer, size_t len)
|
|||
|
||||
if (YES == [session active])
|
||||
{
|
||||
*result = YES;
|
||||
return YES; /* Already connected. */
|
||||
}
|
||||
|
||||
if (YES == isStandardFile)
|
||||
{
|
||||
NSLog(@"Attempt to perform ssl handshake with a standard file");
|
||||
*result = NO;
|
||||
return YES;
|
||||
}
|
||||
|
||||
|
@ -1046,6 +1048,11 @@ GSTLSHandlePush(gnutls_transport_ptr_t handle, const void *buffer, size_t len)
|
|||
|
||||
if (NO == [session handshake])
|
||||
{
|
||||
*result = NO;
|
||||
if (nil == session)
|
||||
{
|
||||
return YES; // Unable to create session
|
||||
}
|
||||
return NO; // Need more.
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue