This file is indexed.

/usr/include/hfsplus/fscheck.h is in libhfsp-dev 1.0.4-15.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
/*
 * libhfs - library for reading and writing Macintosh HFS volumes.
 *
 * This code checks the structures of a HFS+ volume for correctnes
 *
 * Copyright (C) 2000 Klaus Halfmann <klaus.halfmann@feri.de>
 * Original 1996-1998 Robert Leslie <rob@mars.org>
 * Additional work by  Brad Boyer (flar@pants.nu)  
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 *
 * $Id: fscheck.h,v 1.1.1.1 2002/03/05 19:50:28 klaus Exp $
 */

/* Bitflags for check operations */

/* Show normal output only  */
#define HFSPCHECK_NORMAL    0x0000

/* Try to fix any error autmatically (but not yet ...) */
#define HFSPCHECK_AUTO	    0x0001

/* verbose, show more output about almost everything */
#define HFSPCHECK_VERBOSE    0x0002

/* ignore errros (if possible) default stop after first error */
#define HFSPCHECK_IGNOREERR  0x0004

/* On return this variable is set to a 
 * combination of the flags below */
extern int hfspcheck_error;

/* Id like to include those but found no definitions */
#define FSCK_NOERR  0    // No errors
#define FSCK_FSCORR 1    // File system errors corrected
#define FSCK_REBOOT 2    // System should be rebooted
#define FSCK_ERR    4    // File system errors left uncorrected
#define FSCK_ERROPR 8    // Operational error
#define FSCK_USAGE  16   // Usage or syntax error
#define FSCK_SHARED 128  // Shared library error
#define FSCK_FATAL  (FSCK_ERR | FSCK_ERROPR | FSCK_USAGE | FSCK_SHARED)
	// Will not continue checking when one of these is found

/* Do the minimal check required after an unclean mount.
 *
 * The volume should be mounted readonly.
 *
 * returns the highest cnid found. 0 denotes an error.
 * In case of error the volume should not be used at all.
 */
extern UInt32 minimal_check(volume* vol);

/* Do every check that can be imagined (or more :) 
 *
 * returns the highest cnid found. 0 denotes an error.
 * In case of error the volume may still be useable.
 */
extern int maximum_check(char* path, int flags);

/* Do usefull checks, practice will tell what this is.
 *
 * returns the highest cnid found. 0 denotes an error.
 * In case of error the volume may still be useable.
 */
extern int hfsplus_check(char* path, int flags);

/* Dump all raw fork information to stdout */
extern void print_fork(hfsp_fork_raw* f);

/* Check wether all blocks of a fork are marked as allocated.
 *
 * returns number of errors found.
 */
extern int check_forkalloc(volume* vol, hfsp_fork_raw* fork);

/**** Defined in btreecheck.c ****/

/** Intialize catalog btree */
int fscheck_init_cat(btree* bt, volume* vol, hfsp_fork_raw* fork);

/** Intialize catalog btree */
int fscheck_init_extent(btree* bt, volume* vol, hfsp_fork_raw* fork);
   
/** Check a complete btree by traversing it in-oder */
int fscheck_btree(btree *bt);

/** Check all files in leaf nodes */
int fscheck_files(volume* vol);

/** global data used during fsck */
struct {
    UInt32  maxCnid;
    UInt32  macNow; // current date in mac-offset
    int	    verbose;
    int	    ignoreErr;
} fsck_data;