svn commit: r316597 - in head/usr.sbin/makefs: . cd9660

Ed Maste emaste at FreeBSD.org
Fri Apr 7 02:31:56 UTC 2017


Author: emaste
Date: Fri Apr  7 02:31:55 2017
New Revision: 316597
URL: https://svnweb.freebsd.org/changeset/base/316597

Log:
  makefs: Sync with NetBSD (fix unused variable warnings)
  
  NetBSD revs:
  cd9660.c		1.45
  cd9660/cd9660_write.c	1.17
  
  Obtained from:	NetBSD

Modified:
  head/usr.sbin/makefs/cd9660.c
  head/usr.sbin/makefs/cd9660/cd9660_write.c

Modified: head/usr.sbin/makefs/cd9660.c
==============================================================================
--- head/usr.sbin/makefs/cd9660.c	Fri Apr  7 00:33:03 2017	(r316596)
+++ head/usr.sbin/makefs/cd9660.c	Fri Apr  7 02:31:55 2017	(r316597)
@@ -815,15 +815,14 @@ static int
 cd9660_translate_node_common(iso9660_disk *diskStructure, cd9660node *newnode)
 {
 	time_t tstamp = stampst.st_ino ? stampst.st_mtime : time(NULL);
-	int test;
 	u_char flag;
 	char temp[ISO_FILENAME_MAXLENGTH_WITH_PADDING];
 
 	/* Now populate the isoDirRecord structure */
 	memset(temp, 0, ISO_FILENAME_MAXLENGTH_WITH_PADDING);
 
-	test = cd9660_convert_filename(diskStructure, newnode->node->name,
-		temp, !(S_ISDIR(newnode->node->type)));
+	(void)cd9660_convert_filename(diskStructure, newnode->node->name,
+	    temp, !(S_ISDIR(newnode->node->type)));
 
 	flag = ISO_FLAG_CLEAR;
 	if (S_ISDIR(newnode->node->type))
@@ -1111,7 +1110,7 @@ cd9660_rename_filename(iso9660_disk *dis
 		 * See if you can spot them all :)
 		 */
 
-		/*
+#if 0
 		if (diskStructure->isoLevel == 1) {
 			numbts = 8 - digits - delete_chars;
 			if (dot < 0) {
@@ -1122,7 +1121,7 @@ cd9660_rename_filename(iso9660_disk *dis
 				}
 			}
 		}
-		*/
+#endif
 
 		/* (copying just the filename before the '.' */
 		memcpy(tmp, (iter->o_name), numbts);

Modified: head/usr.sbin/makefs/cd9660/cd9660_write.c
==============================================================================
--- head/usr.sbin/makefs/cd9660/cd9660_write.c	Fri Apr  7 00:33:03 2017	(r316596)
+++ head/usr.sbin/makefs/cd9660/cd9660_write.c	Fri Apr  7 02:31:55 2017	(r316597)
@@ -143,10 +143,8 @@ static int
 cd9660_write_volume_descriptors(iso9660_disk *diskStructure, FILE *fd)
 {
 	volume_descriptor *vd_temp = diskStructure->firstVolumeDescriptor;
-	int pos;
 
 	while (vd_temp != NULL) {
-		pos = vd_temp->sector * diskStructure->sectorSize;
 		cd9660_write_filedata(diskStructure, fd, vd_temp->sector,
 		    vd_temp->volumeDescriptorData, 1);
 		vd_temp = vd_temp->next;
@@ -267,7 +265,6 @@ cd9660_write_file(iso9660_disk *diskStru
 	int ret;
 	off_t working_sector;
 	int cur_sector_offset;
-	int written;
 	iso_directory_record_cd9660 temp_record;
 	cd9660node *temp;
 	int rv = 0;
@@ -340,7 +337,7 @@ cd9660_write_file(iso9660_disk *diskStru
 					err(1, "fseeko");
 			}
 			/* Write out the basic ISO directory record */
-			written = fwrite(&temp_record, 1,
+			(void)fwrite(&temp_record, 1,
 			    temp->isoDirRecord->length[0], fd);
 			if (diskStructure->rock_ridge_enabled) {
 				cd9660_write_rr(diskStructure, fd, temp,


More information about the svn-src-head mailing list