(void)snprintf((char*)&attrRec->attrData[0],
sizeof(attrdata) - offsetof(HFSPlusAttrData, attrData),
"%lu", (unsigned long)(p->correct));
- attrRec->attrSize = 1 + strlen((char*)&attrRec->attrData[0]);
+ attrRec->attrSize = (u_int32_t)(1 + strlen((char*)&attrRec->attrData[0]));
bt_data.bufferAddress = attrRec;
recsize = sizeof(HFSPlusAttrData) - 2 + attrRec->attrSize + ((attrRec->attrSize & 1) ? 1 : 0);
bt_data.itemSize = recsize;
if (rec.recordType != kHFSPlusFileRecord) {
retval = IntError(GPtr, R_IntErr);
} else {
- rec.hfsPlusFile.createDate = p->correct;
+ rec.hfsPlusFile.createDate = (u_int32_t)p->correct;
retval = ReplaceBTreeRecord(GPtr->calculatedCatalogFCB, &key, kNoHint, &rec, recsize, &hint);
}
}
}
#endif
- record.hfsPlusFolder.folderCount = p->correct;
+ record.hfsPlusFolder.folderCount = (u_int32_t)p->correct;
result = ReplaceBTreeRecord( GPtr->calculatedCatalogFCB, &foundKey, hint,
&record, recSize, &hint);
if (result) {
Boolean didRepair;
fileID = p->parid;
- badExtentIndex = p->correct;
+ badExtentIndex = (UInt32)p->correct;
extentStartBlock = p->hint;
forkType = p->forkType;
int cmpLongs ( const void *a, const void *b )
{
- return( *(long*)a - *(long*)b );
+ return (int)( *(long*)a - *(long*)b );
}
/* Function: FixOverlappingExtents
break;
};
filename[len] = '\0';
- *filenamelen = strlen (filename);
+ *filenamelen = (unsigned int)strlen (filename);
}
return err;
}
}
/* Do not NULL terminate the string */
- curPtr->namelen = namelen;
+ curPtr->namelen = (unsigned int)namelen;
curPtr->name = malloc(namelen);
if (!curPtr->name) {
err = memFullErr;
// no way to find the original name and this should make it unique within our
// lost+found directory.
sprintf( myString, "%ld", (long)theObjID );
- nameLen = strlen( myString );
+ nameLen = (int)strlen( myString );
if ( isHFSPlus )
{
isHFSPlus = VolumeObjectIsHFSPlus( );
fcbPtr = GPtr->calculatedCatalogFCB;
- nameLen = strlen( (char *)dirName );
+ nameLen = (int)strlen( (char *)dirName );
if ( isHFSPlus )
{