ObjFW  Check-in [dc0a020230]

Overview
Comment:ofzip: Include UID & GID in tar archives
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: dc0a02023033a0c743ce085d98fee1ab41962d9b44e811f58909abdbe47cccc8
User & Date: js on 2017-08-06 22:24:20
Other Links: manifest | tags
Context
2017-08-07
00:20
OFTarArchive: More efficient skipping check-in: 29ee511f56 user: js tags: trunk
2017-08-06
22:24
ofzip: Include UID & GID in tar archives check-in: dc0a020230 user: js tags: trunk
22:21
Add -[OFFileManager getUID:GID:ofItemAtPath:] check-in: 639dd9c244 user: js tags: trunk
Changes

Modified utils/ofzip/TarArchive.m from [b76a2b83a9] to [45466f7ad4].

467
468
469
470
471
472
473

474




475
476
477



478
479
480
481
482
483
484
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492







+

+
+
+
+



+
+
+







		    [fileManager permissionsOfItemAtPath: fileName]];
#endif
		[entry setSize: [fileManager sizeOfFileAtPath: fileName]];
		[entry setModificationDate:
		    [fileManager modificationDateOfItemAtPath: fileName]];

#ifdef OF_FILE_MANAGER_SUPPORTS_OWNER
		uint16_t UID, GID;
		OFString *owner, *group;

		[fileManager getUID: &UID
				GID: &GID
		       ofItemAtPath: fileName];
		[fileManager getOwner: &owner
				group: &group
			 ofItemAtPath: fileName];

		[entry setUID: UID];
		[entry setGID: GID];
		[entry setOwner: owner];
		[entry setGroup: group];
#endif

		if ([fileManager fileExistsAtPath: fileName])
			[entry setType: OF_TAR_ARCHIVE_ENTRY_TYPE_FILE];
		else if ([fileManager directoryExistsAtPath: fileName]) {