ObjFW  Check-in [6192726d32]

Overview
Comment:Add a few casts to make GCC happy.

Also adds a few imports and removes unused code.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 6192726d32e098a74a55424624765c883759e3df639b980af873c50bd31ce702
User & Date: js on 2013-06-23 21:52:12
Other Links: manifest | tags
Context
2013-06-25
20:31
Make backtraces work with ARM EABI. check-in: 6e8777fc03 user: js tags: trunk
2013-06-23
21:52
Add a few casts to make GCC happy. check-in: 6192726d32 user: js tags: trunk
14:15
Improve OFAddressTranslationFailedException. check-in: 3f74e4c5df user: js tags: trunk
Changes

Modified src/OFXMLElement.m from [29fe39b5ac] to [48732d84ce].

211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227

- initWithXMLString: (OFString*)string
{
	void *pool;
	OFXMLParser *parser;
	OFXMLElementBuilder *builder;
	OFXMLElement_OFXMLElementBuilderDelegate *delegate;
	Class c;

	c = [self class];
	[self release];

	if (string == nil)
		@throw [OFInvalidArgumentException exception];

	pool = objc_autoreleasePoolPush();








<

<







211
212
213
214
215
216
217

218

219
220
221
222
223
224
225

- initWithXMLString: (OFString*)string
{
	void *pool;
	OFXMLParser *parser;
	OFXMLElementBuilder *builder;
	OFXMLElement_OFXMLElementBuilderDelegate *delegate;



	[self release];

	if (string == nil)
		@throw [OFInvalidArgumentException exception];

	pool = objc_autoreleasePoolPush();

247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263

- initWithFile: (OFString*)path
{
	void *pool;
	OFXMLParser *parser;
	OFXMLElementBuilder *builder;
	OFXMLElement_OFXMLElementBuilderDelegate *delegate;
	Class c;

	c = [self class];
	[self release];

	pool = objc_autoreleasePoolPush();

	parser = [OFXMLParser parser];
	builder = [OFXMLElementBuilder elementBuilder];
	delegate = [[[OFXMLElement_OFXMLElementBuilderDelegate alloc] init]







<

<







245
246
247
248
249
250
251

252

253
254
255
256
257
258
259

- initWithFile: (OFString*)path
{
	void *pool;
	OFXMLParser *parser;
	OFXMLElementBuilder *builder;
	OFXMLElement_OFXMLElementBuilderDelegate *delegate;



	[self release];

	pool = objc_autoreleasePoolPush();

	parser = [OFXMLParser parser];
	builder = [OFXMLElementBuilder elementBuilder];
	delegate = [[[OFXMLElement_OFXMLElementBuilderDelegate alloc] init]

Modified src/exceptions/OFChangeDirectoryFailedException.m from [f29258b4ad] to [20340581e0].

22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
#import "OFString.h"

#import "common.h"

@implementation OFChangeDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{

	return [[[self alloc] initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {







>
|







22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#import "OFString.h"

#import "common.h"

@implementation OFChangeDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{
	return [[(OFChangeDirectoryFailedException*)[self alloc]
	    initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {

Modified src/exceptions/OFCreateDirectoryFailedException.m from [75c3b48ac7] to [1aaea060ca].

22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
#import "OFString.h"

#import "common.h"

@implementation OFCreateDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{

	return [[[self alloc] initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {







>
|







22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#import "OFString.h"

#import "common.h"

@implementation OFCreateDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{
	return [[(OFCreateDirectoryFailedException*)[self alloc]
	    initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {

Modified src/exceptions/OFDeleteDirectoryFailedException.m from [bb5c3143ac] to [4b3cac7bb3].

20
21
22
23
24
25
26
27
28

29
30
31
32
33
34
35
36

#import "OFDeleteDirectoryFailedException.h"
#import "OFString.h"

#import "common.h"

@implementation OFDeleteDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path_
{

	return [[[self alloc] initWithPath: path_] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {







|

>
|







20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37

#import "OFDeleteDirectoryFailedException.h"
#import "OFString.h"

#import "common.h"

@implementation OFDeleteDirectoryFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{
	return [[(OFDeleteDirectoryFailedException*)[self alloc]
	    initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {

Modified src/exceptions/OFDeleteFileFailedException.m from [889f5dd334] to [742ec5f1c5].

22
23
24
25
26
27
28

29
30
31
32
33
34
35
36
#import "OFString.h"

#import "common.h"

@implementation OFDeleteFileFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{

	return [[[self alloc] initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {







>
|







22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#import "OFString.h"

#import "common.h"

@implementation OFDeleteFileFailedException
+ (instancetype)exceptionWithPath: (OFString*)path
{
	return [[(OFDeleteFileFailedException*)[self alloc]
	    initWithPath: path] autorelease];
}

- init
{
	@try {
		[self doesNotRecognizeSelector: _cmd];
	} @catch (id e) {

Modified src/exceptions/OFReadFailedException.m from [5b0d85c885] to [4d3cf35e83].

14
15
16
17
18
19
20

21
22
23
24
25
26
27
28
29
30
31
 * file.
 */

#include "config.h"

#import "OFReadFailedException.h"
#import "OFString.h"


#import "common.h"

@implementation OFReadFailedException
- (OFString*)description
{
	return [OFString stringWithFormat:
	    @"Failed to read %zu bytes in a stream of type %@! " ERRFMT,
	    _requestedLength, [_stream class], ERRPARAM];
}
@end







>











14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
 * file.
 */

#include "config.h"

#import "OFReadFailedException.h"
#import "OFString.h"
#import "OFStream.h"

#import "common.h"

@implementation OFReadFailedException
- (OFString*)description
{
	return [OFString stringWithFormat:
	    @"Failed to read %zu bytes in a stream of type %@! " ERRFMT,
	    _requestedLength, [_stream class], ERRPARAM];
}
@end

Modified src/exceptions/OFReadOrWriteFailedException.m from [81b4e6d457] to [4ce61d5ebe].

16
17
18
19
20
21
22

23
24
25
26
27
28
29

#include "config.h"

#include <stdlib.h>

#import "OFReadOrWriteFailedException.h"
#import "OFString.h"

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

#import "common.h"

@implementation OFReadOrWriteFailedException







>







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

#include "config.h"

#include <stdlib.h>

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

#import "common.h"

@implementation OFReadOrWriteFailedException

Modified src/exceptions/OFWriteFailedException.m from [93caebcf9a] to [e3c9ad5665].

14
15
16
17
18
19
20

21
22
23
24
25
26
27
28
29
30
31
 * file.
 */

#include "config.h"

#import "OFWriteFailedException.h"
#import "OFString.h"


#import "common.h"

@implementation OFWriteFailedException
- (OFString*)description
{
	return [OFString stringWithFormat:
	    @"Failed to write %zu bytes in a stream of type %@! " ERRFMT,
	    _requestedLength, [_stream class], ERRPARAM];
}
@end







>











14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
 * file.
 */

#include "config.h"

#import "OFWriteFailedException.h"
#import "OFString.h"
#import "OFStream.h"

#import "common.h"

@implementation OFWriteFailedException
- (OFString*)description
{
	return [OFString stringWithFormat:
	    @"Failed to write %zu bytes in a stream of type %@! " ERRFMT,
	    _requestedLength, [_stream class], ERRPARAM];
}
@end