ObjFW  Diff

Differences From Artifact [4e245e9c8a]:

To Artifact [d15067685c]:


101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
}

- (void)writeTablesToFile: (OFString*)file
{
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init], *pool2;

	of_unichar_t i, j;
	BOOL *upper_table_used;
	BOOL *lower_table_used;
	char *casefolding_table_used;
	OFFile *f = [OFFile fileWithPath: file
				    mode: @"wb"];

	upper_table_used = [self allocMemoryWithSize: 0x1100];
	lower_table_used = [self allocMemoryWithSize: 0x1100];
	casefolding_table_used = [self allocMemoryWithSize: 0x1100];

	memset(upper_table_used, 0, 0x1100);
	memset(lower_table_used, 0, 0x1100);
	memset(casefolding_table_used, 0, 0x1100);

	[f writeString: COPYRIGHT
	    @"#include \"config.h\"\n"
	    @"\n"
	    @"#import \"OFString.h\"\n\n"
	    @"static const of_unichar_t nop_page[0x100] = {};\n\n"];

	pool2 = [[OFAutoreleasePool alloc] init];







<
<
<



<
<
<
<
<
<
<
<







101
102
103
104
105
106
107



108
109
110








111
112
113
114
115
116
117
}

- (void)writeTablesToFile: (OFString*)file
{
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init], *pool2;

	of_unichar_t i, j;



	OFFile *f = [OFFile fileWithPath: file
				    mode: @"wb"];









	[f writeString: COPYRIGHT
	    @"#include \"config.h\"\n"
	    @"\n"
	    @"#import \"OFString.h\"\n\n"
	    @"static const of_unichar_t nop_page[0x100] = {};\n\n"];

	pool2 = [[OFAutoreleasePool alloc] init];
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
			[f writeString: @",\n\t"];
		else if (i + 1 < casefolding_size)
			[f writeString: @", "];
	}

	[f writeString: @"\n};\n"];

	[self freeMemory: upper_table_used];
	[self freeMemory: lower_table_used];
	[self freeMemory: casefolding_table_used];

	[pool release];
}

- (void)writeHeaderToFile: (OFString*)file
{
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	OFFile *f = [OFFile fileWithPath: file







<
<
<
<







290
291
292
293
294
295
296




297
298
299
300
301
302
303
			[f writeString: @",\n\t"];
		else if (i + 1 < casefolding_size)
			[f writeString: @", "];
	}

	[f writeString: @"\n};\n"];





	[pool release];
}

- (void)writeHeaderToFile: (OFString*)file
{
	OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
	OFFile *f = [OFFile fileWithPath: file