Lines Matching refs:result

86 	OSErr							result;			/* result */
93 OSErr result; /* result */
137 OSErr result;
142 require_action((NULL != copyBufferPtr) && (0 != copyBufferSize), BadParameter, result = paramErr);
145 result = FSGetForkSize(srcRefNum, &forkSize);
146 require_noerr(result, SourceFSGetForkSizeFailed);
149 result = FSSetForkSize(dstRefNum, fsFromStart, forkSize);
150 require_noerr(result, DestinationFSSetForkSizeFailed);
153 result = FSSetForkPosition(srcRefNum, fsFromStart, 0);
154 require_noerr(result, SourceFSSetForkPositionFailed);
157 result = FSSetForkPosition(dstRefNum, fsFromStart, 0);
158 require_noerr(result, DestinationFSSetForkPositionFailed);
176 require_noerr_action(dstResult, DestinationFSWriteForkFailed, result = dstResult);
179 require_action(eofErr == srcResult, SourceResultNotEofErr, result = srcResult);
182 result = noErr;
192 return ( result );
208 OSErr result;
213 BadParameter, result = paramErr);
219 result = PBHGetVolParmsSync(&pb);
220 require_noerr(result, PBHGetVolParmsSync);
228 return ( result );
238 OSErr result;
242 require_action(NULL != vRefNum, BadParameter, result = paramErr);
245 result = FSGetCatalogInfo(ref, kFSCatInfoVolume, &catalogInfo, NULL, NULL, NULL);
246 require_noerr(result, FSGetCatalogInfo);
254 return ( result );
266 OSErr result;
270 result = FSGetVolumeInfo(volume, 0, NULL,
273 require_noerr(result, FSGetVolumeInfo);
286 return ( result );
297 OSErr result;
300 result = FSGetVolumeInfo(volume, 0, NULL, kFSVolInfoFSInfo, &info, NULL, NULL);
301 require_noerr(result, FSGetVolumeInfo);
314 return ( result );
324 OSErr result;
331 BadParameter, result = paramErr);
338 require_action(NULL != *volumeRefsHandle, NewHandle, result = memFullErr);
344 result = FSGetVolumeInfo(0, volumeIndex, NULL, kFSVolInfoNone, NULL, NULL, &ref);
345 if ( noErr == result )
350 require_noerr_action(memResult, MemoryAllocationFailed, result = memResult);
355 } while ( noErr == result );
358 require(nsvErr == result, FSGetVolumeInfo);
378 return ( result );
392 OSErr result;
395 require_action(NULL != spec, BadParameter, result = paramErr);
397 result = FSGetCatalogInfo(ref, kFSCatInfoNone, NULL, NULL, spec, NULL);
398 require_noerr(result, FSGetCatalogInfo);
403 return ( result );
415 OSErr result;
419 require_action(NULL != ref, BadParameter, result = paramErr);
425 result = PBMakeFSRefSync(&pb);
426 require_noerr(result, PBMakeFSRefSync);
431 return ( result );
444 OSStatus result;
448 require_action(NULL != path, BadParameter, result = paramErr);
451 result = FSMakeFSRef(volRefNum, dirID, name, &ref);
452 require_noerr(result, FSMakeFSRef);
455 result = FSRefMakePath(&ref, path, maxPathSize);
456 require_noerr(result, FSRefMakePath);
462 return ( result );
473 OSStatus result;
477 require_action(NULL != spec, BadParameter, result = paramErr);
480 result = FSPathMakeRef(path, &ref, isDirectory);
481 require_noerr(result, FSPathMakeRef);
484 result = FSGetCatalogInfo(&ref, kFSCatInfoNone, NULL, NULL, spec, NULL);
485 require_noerr(result, FSGetCatalogInfo);
491 return ( result );
504 OSStatus result;
512 require_action(NULL != hfsName, BadParameter, result = paramErr);
521 result = noErr;
533 result = UpgradeScriptInfoToTextEncoding(script, kTextLanguageDontCare, region,
535 if ( paramErr == result )
538 result = UpgradeScriptInfoToTextEncoding(script, kTextLanguageDontCare,
541 if ( noErr != result )
553 result = CreateUnicodeToTextInfo(&uMapping, &utInfo);
554 require_noerr(result, CreateUnicodeToTextInfo);
556 result = ConvertFromUnicodeToText(utInfo, unicodeByteLength, name, kUnicodeLooseMappingsMask,
560 require_noerr(result, ConvertFromUnicodeToText);
566 /* verify the result in debug builds -- there's really not anything you can do if it fails */
573 return ( result );
585 OSStatus result;
591 require_action(NULL != unicodeName, BadParameter, result = paramErr);
598 result = noErr;
610 result = UpgradeScriptInfoToTextEncoding(script, kTextLanguageDontCare, region,
612 if ( paramErr == result )
615 result = UpgradeScriptInfoToTextEncoding(script, kTextLanguageDontCare,
618 if ( noErr != result )
630 result = CreateTextToUnicodeInfo(&uMapping, &tuInfo);
631 require_noerr(result, CreateTextToUnicodeInfo);
633 result = ConvertFromTextToUnicode(tuInfo, hfsName[0], &hfsName[1],
638 require_noerr(result, ConvertFromTextToUnicode);
645 /* verify the result in debug builds -- there's really not anything you can do if it fails */
652 return ( result );
673 OSErr result;
677 require_action(NULL != parentRef, BadParameter, result = paramErr);
679 result = FSGetCatalogInfo(ref, kFSCatInfoNodeID, &catalogInfo, NULL, NULL, parentRef);
680 require_noerr(result, FSGetCatalogInfo);
699 return ( result );
709 OSErr result;
712 require_action(NULL != outName, BadParameter, result = paramErr);
714 result = FSGetCatalogInfo(ref, kFSCatInfoNone, NULL, outName, NULL, NULL);
715 require_noerr(result, FSGetCatalogInfo);
720 return ( result );
731 OSErr result;
746 result = FSGetCatalogInfo(ref, whichInfo, &catalogInfo, NULL, NULL, NULL);
747 require_noerr(result, FSGetCatalogInfo);
760 return ( result );
771 OSErr result;
786 result = FSGetCatalogInfo(ref, whichInfo, &catalogInfo, NULL, NULL, NULL);
787 require_noerr(result, FSGetCatalogInfo);
800 return ( result );
809 OSErr result;
814 result = FSGetCatalogInfo(ref, kFSCatInfoNodeFlags + kFSCatInfoVolume, &catalogInfo, NULL, NULL,NULL);
815 require_noerr(result, FSGetCatalogInfo);
820 result = fLckdErr; /* file is locked */
827 result = FSGetVolumeInfo(catalogInfo.volume, 0, NULL, kFSVolInfoFlags, &volumeInfo, NULL, NULL);
828 require_noerr(result, FSGetVolumeInfo);
832 result = wPrErr; /* volume locked by hardware */
836 result = vLckdErr; /* volume locked by software */
843 return ( result );
854 OSErr result;
871 result = FSGetCatalogInfo(ref, whichInfo, &catalogInfo, NULL, NULL,NULL);
872 require_noerr(result, FSGetCatalogInfo);
875 require_action(0 == (catalogInfo.nodeFlags & kFSNodeIsDirectoryMask), FSRefNotFile, result = notAFileErr);
891 return ( result );
903 OSErr result;
942 result = FSIterateForks(ref, &forkIterator, NULL, forkSizePtr, forkPhysicalSizePtr);
943 if ( noErr == result )
960 } while ( noErr == result );
962 /* any error result other than errFSNoMoreItems is serious */
963 require(errFSNoMoreItems == result, FSIterateForks);
966 result = noErr;
970 return ( result );
979 OSStatus result;
989 result = FSGetCatalogInfo(ref, kFSCatInfoNodeFlags + kFSCatInfoContentMod, &catalogInfo, NULL, NULL, &parentRef);
990 require_noerr(result, FSGetCatalogInfo);
996 result = FSGetCatalogInfo(ref, kFSCatInfoContentMod, &catalogInfo, NULL, NULL, NULL);
997 require_noerr(result, FSGetCatalogInfo);
1003 result = GetUTCDateTime(&catalogInfo.contentModDate, kUTCDefaultOptions);
1004 require_noerr(result, GetUTCDateTime);
1019 result = FSSetCatalogInfo(ref, kFSCatInfoContentMod, &catalogInfo);
1020 require_noerr(result, FSSetCatalogInfo);
1031 result = FNNotify(notifyParent ? &parentRef : ref, kFNDirectoryModifiedMessage, kNilOptions);
1032 require_noerr(result, FNNotify);
1046 return ( result );
1058 OSErr result;
1082 result = FSGetCatalogInfo(ref, whichInfo, &catalogInfo, NULL, NULL, NULL);
1083 require_noerr(result, FSGetCatalogInfo);
1105 return ( result );
1116 OSErr result;
1135 result = FSSetCatalogInfo(ref, whichInfo, &catalogInfo);
1136 require_noerr(result, FSGetCatalogInfo);
1140 return ( result );
1151 OSErr result;
1156 result = FSGetCatalogInfo(ref, kFSCatInfoNodeFlags + kFSCatInfoFinderInfo, &catalogInfo , NULL, NULL, &parentRef);
1157 require_noerr(result, FSGetCatalogInfo);
1160 require_action(0 == (catalogInfo.nodeFlags & kFSNodeIsDirectoryMask), FSRefNotFile, result = notAFileErr);
1175 result = FSSetCatalogInfo(ref, kFSCatInfoFinderInfo, &catalogInfo);
1176 require_noerr(result, FSSetCatalogInfo);
1186 return ( result );
1197 OSErr result;
1202 result = FSGetCatalogInfo(ref, kFSCatInfoFinderInfo, &catalogInfo, NULL, NULL, &parentRef);
1203 require_noerr(result, FSGetCatalogInfo);
1218 result = FSSetCatalogInfo(ref, kFSCatInfoFinderInfo, &catalogInfo);
1219 require_noerr(result, FSSetCatalogInfo);
1228 return ( result );
1312 OSErr result;
1316 result = FSGetCatalogInfo(sourceRef, kFSCatInfoSettableInfo, &catalogInfo, NULL, NULL, NULL);
1317 require_noerr(result, FSGetCatalogInfo);
1330 result = FSSetCatalogInfo(destinationRef, kFSCatInfoSettableInfo, &catalogInfo);
1331 require_noerr(result, FSSetCatalogInfo);
1336 return ( result );
1350 OSErr result;
1360 require_action(NULL != newRef, BadParameter, result = paramErr);
1366 result = FSGetCatalogInfo(destDirectory, kFSCatInfoVolume, &catalogInfo, NULL, NULL, NULL);
1367 require_noerr(result, DestinationBad);
1373 result = FSGetCatalogInfo(ref, kFSCatInfoTextEncoding + kFSCatInfoVolume, &catalogInfo, &originalName, NULL, &originalDirectory);
1374 require_noerr(result, SourceBad);
1380 require_action(vRefNum == catalogInfo.volume, NotSameVolume, result = diffVolErr);
1388 result = GenerateUniqueHFSUniStr(&theSeed, &originalDirectory, destDirectory, &uniqueName);
1389 require_noerr(result, GenerateUniqueHFSUniStrFailed);
1392 result = FSRenameUnicode(ref, uniqueName.length, uniqueName.unicode, kTextEncodingUnknown, newRef);
1393 require_noerr(result, FSRenameUnicodeBeforeMoveFailed);
1398 result = FSMoveObject(newRef, destDirectory, newRef);
1399 require_noerr(result, FSMoveObjectAfterRenameFailed);
1403 result = FSRenameUnicode(ref, nameLength, name, textEncodingHint, newRef);
1404 require_noerr(result, FSRenameUnicodeAfterMoveFailed);
1409 result = FSMoveObject(newRef, destDirectory, newRef);
1410 require_noerr(result, FSMoveObjectNoRenameFailed);
1413 return ( result );
1443 return ( result );
1475 theGlobals->result = FSOpenIterator(container, kFSIterateFlat + kFSIterateDelete, &iterator);
1476 require_noerr(theGlobals->result, FSOpenIterator);
1482 theGlobals->result = FSGetCatalogInfoBulk(iterator, 1, &theGlobals->actualObjects,
1485 if ( (noErr == theGlobals->result) && (1 == theGlobals->actualObjects) )
1497 if ( noErr == theGlobals->result )
1502 /* then attempt to unlock it (ignore result since FSDeleteObject will set it correctly) */
1507 theGlobals->result = FSDeleteObject(&itemToDelete);
1510 } while ( noErr == theGlobals->result );
1513 if ( errFSNoMoreItems == theGlobals->result )
1515 theGlobals->result = noErr;
1537 return ( theGlobals.result );
1546 OSErr result;
1550 result = FSGetCatalogInfo(container, kFSCatInfoNodeFlags, &catalogInfo, NULL, NULL,NULL);
1551 require_noerr(result, FSGetCatalogInfo);
1554 require_action(0 != (catalogInfo.nodeFlags & kFSNodeIsDirectoryMask), ContainerNotDirectory, result = dirNFErr);
1557 result = FSDeleteContainerContents(container);
1558 require_noerr(result, FSDeleteContainerContents);
1563 /* then attempt to unlock container (ignore result since FSDeleteObject will set it correctly) */
1569 result = FSDeleteObject(container);
1575 return ( result );
1609 theGlobals->result = FSOpenIterator(&theGlobals->ref, kFSIterateFlat, &iterator);
1610 require_noerr(theGlobals->result, FSOpenIterator);
1617 theGlobals->result = FSGetCatalogInfoBulk(iterator, 1, &theGlobals->actualObjects,
1620 if ( (noErr == theGlobals->result || errFSNoMoreItems == theGlobals->result) &&
1640 } while ( (noErr == theGlobals->result) && (!theGlobals->quitFlag) );
1644 if ( (errFSNoMoreItems == theGlobals->result) ||
1645 (afpAccessDenied == theGlobals->result) )
1647 theGlobals->result = noErr;
1673 OSErr result;
1677 require_action(iterateFilter != NULL, NoIterateFilter, result = paramErr);
1708 theGlobals.result = noErr;
1713 result = theGlobals.result;
1714 require_noerr(result, FSIterateContainerLevel);
1719 return ( result );
1734 OSErr result;
1743 BadParameter, result = paramErr);
1748 require_action(NULL != *refsHandle, NewHandle, result = memFullErr);
1751 result = FSOpenIterator(container, kFSIterateFlat, &iterator);
1752 require_noerr(result, FSOpenIterator);
1757 result = FSGetCatalogInfoBulk(iterator, kMaxItemsPerBulkCall, &actualObjects,
1766 /* any result other than noErr and errFSNoMoreItems is serious */
1767 require((noErr == result) || (errFSNoMoreItems == result), FSGetCatalogInfoBulk);
1775 require_noerr_action(memResult, MemoryAllocationFailed, result = memResult);
1779 } while ( noErr == result );
1805 return ( result );
1832 OSErr result;
1845 result = noErr;
1846 while ( fnfErr != result )
1857 result = PBMakeFSRefUnicodeSync(&pb);
1858 if ( fnfErr == result )
1862 result = PBMakeFSRefUnicodeSync(&pb);
1863 if ( fnfErr != result )
1866 require_noerr(result, Dir2PBMakeFSRefUnicodeSyncFailed);
1872 require_noerr(result, Dir1PBMakeFSRefUnicodeSyncFailed);
1881 result = noErr;
1886 return ( result );
1910 OSErr result;
1927 require_action((NULL != newSourceRef) && (NULL != newDestRef), BadParameter, result = paramErr);
1937 result = FSGetCatalogInfo(&sourceCurrentRef, kFSCatInfoVolume, &sourceCatalogInfo, NULL, NULL, NULL);
1938 require_noerr(result, DetermineSourceVRefNumFailed);
1941 result = FSGetVolParms(sourceCatalogInfo.volume, sizeof(GetVolParmsInfoBuffer),
1943 if ( (noErr == result) && VolSupportsFSExchangeObjects(&volParmsInfo) )
1946 result = FSExchangeObjects(sourceRef, destRef);
1956 result = FSGetCatalogInfo(&sourceCurrentRef, kGetCatInformationMask, &sourceCatalogInfo, &sourceName, NULL, &sourceParentRef);
1957 require_noerr(result, SourceFSGetCatalogInfoFailed);
1959 result = FSGetCatalogInfo(&destCurrentRef, kGetCatInformationMask, &destCatalogInfo, &destName, NULL, &destParentRef);
1960 require_noerr(result, DestFSGetCatalogInfoFailed);
1963 require_action(sourceCatalogInfo.volume == destCatalogInfo.volume, NotSameVolume, result = diffVolErr);
1967 (0 == (destCatalogInfo.nodeFlags & kFSNodeIsDirectoryMask)), NotAFile, result = notAFileErr);
1972 result = GenerateUniqueHFSUniStr(&theSeed, &sourceParentRef, &destParentRef, &sourceUniqueName);
1973 require_noerr(result, GenerateUniqueHFSUniStr1Failed);
1975 result = GenerateUniqueHFSUniStr(&theSeed, &sourceParentRef, &destParentRef, &destUniqueName);
1976 require_noerr(result, GenerateUniqueHFSUniStr2Failed);
1979 result = FSRenameUnicode(&sourceCurrentRef, sourceUniqueName.length, sourceUniqueName.unicode, kTextEncodingUnknown, newSourceRef);
1980 require_noerr(result, FSRenameUnicode1Failed);
1984 result = FSRenameUnicode(&destCurrentRef, destUniqueName.length, destUniqueName.unicode, kTextEncodingUnknown, newDestRef);
1985 require_noerr(result, FSRenameUnicode2Failed);
1993 result = FSMoveObject(&sourceCurrentRef, &destParentRef, newSourceRef);
1994 require_noerr(result, FSMoveObject1Failed);
1998 result = FSMoveObject(&destCurrentRef, &sourceParentRef, newDestRef);
1999 require_noerr(result, FSMoveObject2Failed);
2009 result = FSSetCatalogInfo(&sourceCurrentRef, kSetCatinformationMask, &destCatalogInfo);
2010 require_noerr(result, FSSetCatalogInfo1Failed);
2013 result = FSSetCatalogInfo(&destCurrentRef, kSetCatinformationMask, &sourceCatalogInfo);
2014 require_noerr(result, FSSetCatalogInfo2Failed);
2017 result = FSRenameUnicode(&sourceCurrentRef, destName.length, destName.unicode, destCatalogInfo.textEncodingHint, newSourceRef);
2018 require_noerr(result, FSRenameUnicode3Failed);
2022 result = FSRenameUnicode(&destCurrentRef, sourceName.length, sourceName.unicode, sourceCatalogInfo.textEncodingHint, newDestRef);
2023 require_noerr(result, FSRenameUnicode4Failed);
2030 return ( result );
2098 return ( result );
2117 OSErr result;
2124 result = PBLockRangeSync(&pb);
2125 require_noerr(result, PBLockRangeSync);
2129 return ( result );
2144 OSErr result;
2151 result = PBUnlockRangeSync(&pb);
2152 require_noerr(result, PBUnlockRangeSync);
2156 return ( result );
2168 OSErr result;
2173 result = FSGetCatalogInfo(ref, kFSCatInfoNone, NULL, NULL, &spec, NULL);
2174 require_noerr(result, FSGetCatalogInfo);
2180 result = PBHGetDirAccessSync(&pb);
2181 require_noerr(result, PBHGetDirAccessSync);
2200 return ( result );
2212 OSErr result;
2226 result = FSGetCatalogInfo(ref, kFSCatInfoNone, NULL, NULL, &spec, NULL);
2227 require_noerr(result, FSGetCatalogInfo);
2236 result = PBHSetDirAccessSync(&pb);
2237 require_noerr(result, PBHSetDirAccessSync);
2242 return ( result );
2252 OSErr result;
2256 require_action(NULL != size, BadParameter, result = paramErr);
2261 result = PBGetVolMountInfoSize(&pb);
2262 require_noerr(result, PBGetVolMountInfoSize);
2267 return ( result );
2277 OSErr result;
2281 require_action(NULL != volMountInfo, BadParameter, result = paramErr);
2286 result = PBGetVolMountInfo(&pb);
2287 require_noerr(result, PBGetVolMountInfo);
2292 return ( result );
2305 OSErr result;
2309 require_action(NULL != volRefNum, BadParameter, result = paramErr);
2312 result = PBVolumeMount(&pb);
2313 require_noerr(result, PBVolumeMount);
2321 return ( result );
2334 OSErr result;
2338 require_action(NULL != name, BadParameter, result = paramErr);
2345 result = PBHMapIDSync(&pb);
2346 require_noerr(result, PBHMapIDSync);
2351 return ( result );
2363 OSErr result;
2367 require_action(NULL != ugID, BadParameter, result = paramErr);
2373 result = PBHMapNameSync(&pb);
2374 require_noerr(result, PBHMapNameSync);
2382 return ( result );
2396 OSErr result;
2405 result = FSGetCatalogInfo(srcFileRef, kFSCatInfoNone, NULL, NULL, &srcFileSpec, NULL);
2406 require_noerr(result, FSGetCatalogInfo_srcFileRef);
2409 result = FSGetVolParms(srcFileSpec.vRefNum, sizeof(GetVolParmsInfoBuffer),
2411 require_action((noErr == result) && VolHasCopyFile(&volParmsInfo),
2412 NoCopyFileSupport, result = paramErr);
2415 result = FSGetCatalogInfo(dstDirectoryRef, kFSCatInfoVolume + kFSCatInfoNodeID,
2417 require_noerr(result, FSGetCatalogInfo_dstDirectoryRef);
2428 result = UnicodeNameGetHFSName(nameLength, copyName, textEncodingHint, false, hfsName);
2429 require_noerr(result, UnicodeNameGetHFSName);
2437 result = PBHCopyFileSync(&pb);
2438 require_noerr(result, PBHCopyFileSync);
2452 return ( result );
2466 OSErr result;
2475 result = FSGetCatalogInfo(srcFileRef, kFSCatInfoNone, NULL, NULL, &srcFileSpec, NULL);
2476 require_noerr(result, FSGetCatalogInfo_srcFileRef);
2479 result = FSGetVolParms(srcFileSpec.vRefNum, sizeof(GetVolParmsInfoBuffer),
2481 require_action((noErr == result) && VolHasMoveRename(&volParmsInfo),
2482 NoMoveRenameSupport, result = paramErr);
2485 result = FSGetCatalogInfo(dstDirectoryRef, kFSCatInfoVolume + kFSCatInfoNodeID,
2487 require_noerr(result, FSGetCatalogInfo_dstDirectoryRef);
2490 require_action(srcFileSpec.vRefNum == catalogInfo.volume, NotSameVolume, result = diffVolErr);
2500 result = UnicodeNameGetHFSName(nameLength, moveName, textEncodingHint, false, hfsName);
2501 require_noerr(result, UnicodeNameGetHFSName);
2509 result = PBHMoveRenameSync(&pb);
2510 require_noerr(result, PBHMoveRenameSync);
2525 return ( result );
2540 OSErr result;
2545 require_action(NULL != ref, BadParameter, result = paramErr);
2552 result = PBResolveFileIDRefSync((HParmBlkPtr)&pb);
2553 require_noerr(result, PBResolveFileIDRefSync);
2556 result = FSMakeFSRef(volRefNum, pb.ioSrcDirID, tempStr, ref);
2557 require_noerr(result, FSMakeFSRef);
2563 return ( result );
2573 OSErr result;
2578 require_action(NULL != fileID, BadParameter, result = paramErr);
2581 result = FSGetCatalogInfo(ref, kFSCatInfoNone, NULL, NULL, &spec, NULL);
2582 require_noerr(result, FSGetCatalogInfo);
2588 result = PBCreateFileIDRefSync((HParmBlkPtr)&pb);
2589 require((noErr == result) || (fidExists == result) || (afpIDExists == result),
2599 return ( result );
2691 OSErr result;
2697 require_action((NULL != newDefault) && (NULL != oldDefault), BadParameter, result = paramErr);
2700 result = FSGetCatalogInfo(newDefault,
2703 require_noerr(result, FSGetCatalogInfo);
2707 result = dirNFErr);
2710 result = HGetVol(NULL, &vRefNum, &dirID);
2711 require_noerr(result, HGetVol);
2714 result = FSMakeFSRef(vRefNum, dirID, NULL, oldDefault);
2715 require_noerr(result, FSMakeFSRef);
2718 result = HSetVol(NULL, catalogInfo.volume, catalogInfo.nodeID);
2719 require_noerr(result, HSetVol);
2728 return ( result );
2737 OSErr result;
2741 require_action(NULL != oldDefault, BadParameter, result = paramErr);
2744 result = FSGetCatalogInfo(oldDefault,
2747 require_noerr(result, FSGetCatalogInfo);
2751 result = dirNFErr);
2754 result = HSetVol(NULL, catalogInfo.volume, catalogInfo.nodeID);
2755 require_noerr(result, HSetVol);
2762 return ( result );