* The direction parameter must be kSwapBTNodeBigToHost or kSwapBTNodeHostToBig.
* The kSwapBTNodeHeaderRecordOnly "direction" is not valid for these routines.
*/
-static int hfs_swap_HFSPlusBTInternalNode (BlockDescriptor *src, HFSCatalogNodeID fileID, enum HFSBTSwapDirection direction);
-static int hfs_swap_HFSBTInternalNode (BlockDescriptor *src, HFSCatalogNodeID fileID, enum HFSBTSwapDirection direction);
+int hfs_swap_HFSPlusBTInternalNode (BlockDescriptor *src, HFSCatalogNodeID fileID, enum HFSBTSwapDirection direction);
+int hfs_swap_HFSBTInternalNode (BlockDescriptor *src, HFSCatalogNodeID fileID, enum HFSBTSwapDirection direction);
+void hfs_swap_HFSPlusForkData (HFSPlusForkData *src);
/*
* hfs_swap_HFSPlusForkData
*/
-static void
+void
hfs_swap_HFSPlusForkData (
HFSPlusForkData *src
)
/*
* Check srcDesc->height. Don't swap it because it's only one byte.
*/
- if (srcDesc->height > btcb->treeDepth) {
+ if (srcDesc->height > kMaxTreeDepth) {
printf("hfs_swap_BTNode: invalid node height (%d)\n", srcDesc->height);
error = fsBTInvalidHeaderErr;
goto fail;
/*
* Check srcDesc->height. Don't swap it because it's only one byte.
*/
- if (srcDesc->height > btcb->treeDepth) {
+ if (srcDesc->height > kMaxTreeDepth) {
panic("hfs_UNswap_BTNode: invalid node height (%d)\n", srcDesc->height);
error = fsBTInvalidHeaderErr;
goto fail;
return (error);
}
-static int
+int
hfs_swap_HFSPlusBTInternalNode (
BlockDescriptor *src,
HFSCatalogNodeID fileID,
return (0);
}
-static int
+int
hfs_swap_HFSBTInternalNode (
BlockDescriptor *src,
HFSCatalogNodeID fileID,