ObjFW  Diff

Differences From Artifact [74aee00696]:

To Artifact [a5ac8c3823]:


16
17
18
19
20
21
22

23


24
25
26
27
28
29
30
16
17
18
19
20
21
22
23

24
25
26
27
28
29
30
31
32







+
-
+
+








#include "config.h"

#include <stdlib.h>

#import "OFReadOrWriteFailedException.h"
#import "OFString.h"
#ifdef OF_HAVE_SOCKETS
#import "OFStreamSocket.h"
# import "OFStreamSocket.h"
#endif

#import "common.h"

@implementation OFReadOrWriteFailedException
+ (instancetype)exceptionWithClass: (Class)class
			    stream: (OFStream*)stream
		   requestedLength: (size_t)requestedLength
51
52
53
54
55
56
57

58
59
60

61
62
63
64
65
66
67
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71







+



+







  requestedLength: (size_t)requestedLength
{
	self = [super initWithClass: class];

	_stream = [stream retain];
	_requestedLength = requestedLength;

#ifdef OF_HAVE_SOCKETS
	if ([class isSubclassOfClass: [OFStreamSocket class]])
		_errNo = GET_SOCK_ERRNO;
	else
#endif
		_errNo = GET_ERRNO;

	return self;
}

- (void)dealloc
{