ObjFW  Check-in [f70ea939ba]

Overview
Comment:OFUUID: Use lowercase as per RFC 4122 Section 3
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: f70ea939ba93043d723ab269c203542119d923bb418b69f671d8f97fe83df163
User & Date: js on 2022-01-17 08:18:38
Other Links: manifest | tags
Context
2022-01-22
17:07
Make TLS implementation selectable & disableable check-in: 4d6bc31b06 user: js tags: trunk
2022-01-17
08:18
OFUUID: Use lowercase as per RFC 4122 Section 3 check-in: f70ea939ba user: js tags: trunk
2022-01-16
18:23
OFZIPArchive: Throw exception on closed archive check-in: 44bf860dc2 user: js tags: trunk
Changes

Modified src/OFUUID.m from [2d4d775406] to [9c5bf6f593].

219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
{
	memcpy(bytes, _bytes, sizeof(_bytes));
}

- (OFString *)UUIDString
{
	return [OFString stringWithFormat:
	    @"%02X%02X%02X%02X-%02X%02X-%02X%02X-%02X%02X-"
	    @"%02X%02X%02X%02X%02X%02X",
	    _bytes[0], _bytes[1], _bytes[2], _bytes[3],
	    _bytes[4], _bytes[5], _bytes[6], _bytes[7],
	    _bytes[8], _bytes[9], _bytes[10], _bytes[11],
	    _bytes[12], _bytes[13], _bytes[14], _bytes[15]];
}

- (OFString *)description







|
|







219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
{
	memcpy(bytes, _bytes, sizeof(_bytes));
}

- (OFString *)UUIDString
{
	return [OFString stringWithFormat:
	    @"%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-"
	    @"%02x%02x%02x%02x%02x%02x",
	    _bytes[0], _bytes[1], _bytes[2], _bytes[3],
	    _bytes[4], _bytes[5], _bytes[6], _bytes[7],
	    _bytes[8], _bytes[9], _bytes[10], _bytes[11],
	    _bytes[12], _bytes[13], _bytes[14], _bytes[15]];
}

- (OFString *)description

Modified tests/serialization.xml from [1df911f605] to [d106910237].

1
2
3
4
5
6
7
8
9
10
11
12
<?xml version='1.0' encoding='UTF-8'?>
<serialization xmlns='https://objfw.nil.im/serialization' version='1'>
  <OFMutableDictionary>
    <key>
      <OFUUID>01234567-89AB-CDEF-FEDC-BA9876543210</OFUUID>
    </key>
    <object>
      <OFString>uuid</OFString>
    </object>
    <key>
      <OFString>Blub</OFString>
    </key>




|







1
2
3
4
5
6
7
8
9
10
11
12
<?xml version='1.0' encoding='UTF-8'?>
<serialization xmlns='https://objfw.nil.im/serialization' version='1'>
  <OFMutableDictionary>
    <key>
      <OFUUID>01234567-89ab-cdef-fedc-ba9876543210</OFUUID>
    </key>
    <object>
      <OFString>uuid</OFString>
    </object>
    <key>
      <OFString>Blub</OFString>
    </key>