Add an header guard to prevent multiple inclusion
This commit is contained in:
parent
fb96d07f8c
commit
25c8dba564
124 changed files with 572 additions and 11 deletions
|
@ -20,6 +20,8 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _ADDPART_H
|
||||
#define _ADDPART_H
|
||||
/*@
|
||||
@ requires \valid(disk);
|
||||
@ requires list_part == \null || \valid_read(list_part);
|
||||
|
@ -29,3 +31,4 @@
|
|||
@ ensures valid_read_string(*current_cmd);
|
||||
@*/
|
||||
list_part_t *add_partition_cli(disk_t *disk, list_part_t *list_part, char **current_cmd);
|
||||
#endif
|
||||
|
|
|
@ -20,4 +20,15 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _ADDPARTN_H
|
||||
#define _ADDPARTN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
list_part_t *add_partition_ncurses(disk_t *disk, list_part_t *list_part);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _ADV_H
|
||||
#define _ADV_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -39,3 +42,4 @@ int is_part_linux(const partition_t *partition);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _ANALYSE_H
|
||||
#define _ANALYSE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -40,3 +42,4 @@ int check_linux(disk_t *disk, partition_t *partition, const int verbose);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _ASKLOC_H
|
||||
#define _ASKLOC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -33,3 +36,4 @@ char *get_default_location(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,9 +19,19 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _AUTOSET_H
|
||||
#define _AUTOSET_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*@
|
||||
@ requires \valid(disk_car);
|
||||
@ assigns disk_car->unit;
|
||||
@*/
|
||||
void autoset_unit(disk_t *disk_car);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _BFS_H
|
||||
#define _BFS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -101,3 +103,4 @@ int recover_BeFS(const disk_t *disk_car, const struct disk_super_block *beos_blo
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _BTRFS_H
|
||||
#define _BTRFS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -144,3 +146,4 @@ int recover_btrfs(const disk_t *disk_car, const struct btrfs_super_block *sb,par
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _CHGARCH_H
|
||||
#define _CHGARCH_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -34,3 +36,4 @@ int change_arch_type_cli(disk_t *disk, const int verbose, char**current_cmd);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _CHGARCHN_H
|
||||
#define _CHGARCHN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +31,4 @@ int change_arch_type_ncurses(disk_t *disk_car, const int verbose);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _CHGTYPE_H
|
||||
#define _CHGTYPE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void change_part_type_cli(const disk_t *disk_car,partition_t *partition, char **
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _CHGTYPEN_H
|
||||
#define _CHGTYPEN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void change_part_type_ncurses(const disk_t *disk, partition_t *partition);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _CRAMFS_H
|
||||
#define _CRAMFS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -88,3 +90,4 @@ int recover_cramfs(const disk_t *disk_car, const struct cramfs_super *sb, partit
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _CRC_H
|
||||
#define _CRC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -38,3 +40,4 @@ unsigned int get_crc32(const void *s, const unsigned int len, const uint32_t see
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,10 +19,15 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _DIMAGE_H
|
||||
#define _DIMAGE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
int disk_image(disk_t *disk_car, const partition_t *partition, const char *image_dd);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,12 +19,16 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _DIRPART_H
|
||||
#define _DIRPART_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include "dir.h"
|
||||
dir_partition_t dir_partition(disk_t *disk_car, const partition_t *partition, const int verbose, const int expert, char **current_cmd);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _DISKACC_H
|
||||
#define _DISKACC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int interface_check_disk_access(disk_t *disk_car, char **current_cmd);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _DISKCAPA_H
|
||||
#define _DISKCAPA_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int interface_check_disk_capacity(disk_t *disk_car);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EDIT_H
|
||||
#define _EDIT_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void interface_editor(disk_t *disk_car);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EWF_H
|
||||
#define _EWF_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -35,3 +37,4 @@ const char*td_ewf_version(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXFAT_H
|
||||
#define _EXFAT_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -101,3 +103,4 @@ int test_exFAT(const struct exfat_super_block *exfat_header);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXFAT_DIR_H
|
||||
#define _EXFAT_DIR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ dir_partition_t dir_partition_exfat_init(disk_t *disk_car, const partition_t *pa
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXFATP_H
|
||||
#define _EXFATP_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ unsigned int exfat_remove_used_space(disk_t *disk, const partition_t *partition,
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2_H
|
||||
#define _EXT2_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -207,3 +209,4 @@ int recover_EXT2(const disk_t *disk_car, const struct ext2_super_block *sb, part
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef EXT2_COMMON_H
|
||||
#define EXT2_COMMON_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -30,3 +32,4 @@ int test_EXT2(const struct ext2_super_block *sb, const partition_t *partition);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2_DIR_H
|
||||
#define _EXT2_DIR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +31,4 @@ const char*td_ext2fs_version(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,10 +19,17 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2_INC_H
|
||||
#define _EXT2_INC_H
|
||||
|
||||
#if defined(__FRAMAC__) || defined(MAIN_photorec)
|
||||
#undef HAVE_LIBEXT2FS
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_LIBEXT2FS)
|
||||
struct ext2_dir_struct {
|
||||
file_info_t *dir_list;
|
||||
|
@ -31,3 +38,8 @@ struct ext2_dir_struct {
|
|||
dir_data_t *dir_data;
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2_SB_H
|
||||
#define _EXT2_SB_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int interface_superblock(disk_t *disk_car, const list_part_t *list_part, char**c
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2_SBN_H
|
||||
#define _EXT2_SBN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *search_superblock(disk_t *disk_car, partition_t *partition, const i
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2GRP_H
|
||||
#define _EXT2GRP_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +31,4 @@ unsigned int ext2_fix_inode(alloc_data_t *list_search_space, disk_t *disk, const
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,12 +19,17 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _EXT2P_H
|
||||
#define _EXT2P_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LIBEXT2FS
|
||||
unsigned int ext2_remove_used_space(disk_t *disk, const partition_t *partition, alloc_data_t *list_search_space);
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
10
src/f2fs.h
10
src/f2fs.h
|
@ -19,7 +19,17 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _F2FS_H
|
||||
#define _F2FS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
int check_f2fs(disk_t *disk, partition_t *partition);
|
||||
int test_f2fs(const struct f2fs_super_block *hdr);
|
||||
int recover_f2fs(const disk_t *disk, const struct f2fs_super_block *hdr, partition_t *partition);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FAT1X_H
|
||||
#define _FAT1X_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int fat1x_boot_sector(disk_t *disk_car, partition_t *partition, const int verbos
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FAT32_H
|
||||
#define _FAT32_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int fat32_boot_sector(disk_t *disk_car, partition_t *partition, const int verbos
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FAT_DIR_H
|
||||
#define _FAT_DIR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -30,3 +32,4 @@ dir_partition_t dir_partition_fat_init(disk_t *disk_car, const partition_t *part
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FATP_H
|
||||
#define _FATP_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ unsigned int fat_remove_used_space(disk_t *disk_car,const partition_t *partition
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FATX_H
|
||||
#define _FATX_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -38,3 +40,4 @@ int recover_FATX(const struct disk_fatx *fatx_block, partition_t *partition);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_DOC_H
|
||||
#define _FILE_DOC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void file_check_doc_aux(file_recovery_t *file_recovery, const uint64_t offset);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_FOUND_H
|
||||
#define _FILE_FOUND_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ alloc_data_t *file_found(alloc_data_t *current_search_space, const uint64_t offs
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_GZ_H
|
||||
#define _FILE_GZ_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,4 +30,4 @@ const char*td_zlib_version(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_JPG_H
|
||||
#define _FILE_JPG_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ const char*td_jpeg_version(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_TAR_H
|
||||
#define _FILE_TAR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int header_check_tar(const unsigned char *buffer, const unsigned int buffer_size
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,12 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _FILE_TXT_H
|
||||
#define _FILE_TXT_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*@
|
||||
@ requires buf_len> 0;
|
||||
@ requires \valid_read(buffer+(0..buf_len-1));
|
||||
|
@ -26,3 +32,7 @@
|
|||
@ assigns \nothing;
|
||||
@*/
|
||||
int UTFsize(const unsigned char *buffer, const unsigned int buf_len);
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _GEOMETRY_H
|
||||
#define _GEOMETRY_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -51,3 +53,4 @@ int change_geometry_cli(disk_t *disk, char **current_cmd);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _GEOMETRYN_H
|
||||
#define _GEOMETRYN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int change_geometry_ncurses(disk_t *disk);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _GFS2_H
|
||||
#define _GFS2_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -84,3 +86,4 @@ int recover_gfs2(const disk_t *disk_car, const struct gfs2_sb *sb, partition_t *
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _GODMODE_H
|
||||
#define _GODMODE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -30,3 +32,4 @@ void only_one_bootable( list_part_t *list_part, const list_part_t *part_boot);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,11 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _GUID_CMP_H
|
||||
#define _GUID_CMP_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*@
|
||||
@ assigns \nothing;
|
||||
|
@ -28,3 +33,7 @@ static inline int guid_cmp (const efi_guid_t left, const efi_guid_t right)
|
|||
return memcmp(&left, &right, sizeof(efi_guid_t));
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _GUID_CPY_H
|
||||
#define _GUID_CPY_H
|
||||
/*@ requires \valid(dst);
|
||||
@ requires \valid_read(src);
|
||||
@ requires separation:
|
||||
|
@ -32,5 +34,4 @@ static inline void guid_cpy (efi_guid_t *dst, const efi_guid_t *src)
|
|||
{
|
||||
memcpy(dst, src, sizeof(efi_guid_t));
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _HDCACHE_H
|
||||
#define _HDCACHE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -32,3 +34,4 @@ disk_t *new_diskcache(disk_t *disk_car, const unsigned int cache_size_min);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _HIDDEN_H
|
||||
#define _HIDDEN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int is_hpa_or_dco(const disk_t *disk);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _HIDDENN_H
|
||||
#define _HIDDENN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int interface_check_hidden_ncurses(disk_t *disk, const int hpa_dco);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _HPA_DCO_H
|
||||
#define _HPA_DCO_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void disk_get_hpa_dco(const int hd_h, disk_t *disk_car);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _INTRF_H
|
||||
#define _INTRF_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -79,3 +81,4 @@ int get_partition_status(const partition_t *partition);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _INTRFACE_H
|
||||
#define _INTRFACE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +31,4 @@ void interface_list(disk_t *disk_car, const int verbose, const int saveheader, c
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
|
||||
*/
|
||||
|
||||
#ifndef _INTRFN_H
|
||||
#define _INTRFN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -73,3 +75,4 @@ void display_message(const char*msg);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _IO_REDIR_H
|
||||
#define _IO_REDIR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int io_redir_del_redir(disk_t *disk_car, uint64_t org_offset);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _ISO_H
|
||||
#define _ISO_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -38,3 +41,4 @@ int recover_ISO(const struct iso_primary_descriptor *iso, partition_t *partition
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _JFS_H
|
||||
#define _JFS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -44,3 +46,4 @@ int recover_JFS(const disk_t *disk_car, const struct jfs_superblock *sb, partiti
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -17,6 +17,16 @@
|
|||
with this program; if not, write the Free Software Foundation, Inc., 51
|
||||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*/
|
||||
#ifndef _LIST_SORT_H
|
||||
#define _LIST_SORT_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void td_list_sort(struct td_list_head *head,
|
||||
int (*cmp)(const struct td_list_head *a, const struct td_list_head *b));
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
|
||||
LUKS on-disk-format: http://luks.endorphin.org/spec
|
||||
*/
|
||||
#ifndef _LUKS_H
|
||||
#define _LUKS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -62,3 +64,4 @@ int recover_LUKS(const disk_t *disk_car, const struct luks_phdr *sb,partition_t
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -21,6 +21,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _MEMMEM_H
|
||||
#define _MEMMEM_H
|
||||
|
||||
/*@
|
||||
@ requires \valid_read((const char *)haystack+(0..haystack_len-1));
|
||||
|
@ -53,3 +55,4 @@ static inline const void *td_memmem(const void *haystack, const unsigned int hay
|
|||
return (const void *) begin;
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _MISC_H
|
||||
#define _MISC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -37,3 +39,4 @@ const char *get_compilation_date(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NETWARE_H
|
||||
#define _NETWARE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -50,3 +52,4 @@ int recover_netware(const disk_t *disk_car, const struct disk_netware *netware_b
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
24
src/next.h
24
src/next.h
|
@ -1,3 +1,26 @@
|
|||
/*
|
||||
|
||||
File: next.h
|
||||
|
||||
Copyright (C) 2020 Christophe GRENIER <grenier@cgsecurity.org>
|
||||
|
||||
This software 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 the Free Software Foundation, Inc., 51
|
||||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NEXT_H
|
||||
#define _NEXT_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -8,3 +31,4 @@ uint64_t search_location_update(const uint64_t location);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,11 +19,15 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NODISK_H
|
||||
#define _NODISK_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
int intrf_no_disk_ncurses(const char *prog_name);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFS_H
|
||||
#define _NTFS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -261,3 +263,4 @@ long int ntfs_get_first_rl_element(const ntfs_attribnonresident *attrnr, const c
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFS_DIR_H
|
||||
#define _NTFS_DIR_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +31,4 @@ const char*td_ntfs_version(void);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFS_FIX_H
|
||||
#define _NTFS_FIX_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int repair_MFT(disk_t *disk_car, partition_t *partition, const int verbose, cons
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,12 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFS_INC_H
|
||||
#define _NTFS_INC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_LIBNTFS) || defined(HAVE_LIBNTFS3G)
|
||||
struct ntfs_dir_struct {
|
||||
file_info_t *dir_list;
|
||||
|
@ -31,3 +37,8 @@ struct ntfs_dir_struct {
|
|||
#endif
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFS_UDL_H
|
||||
#define _NTFS_UDL_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int ntfs_undelete_part(disk_t *disk_car, const partition_t *partition, const int
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,11 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifdef __FRAMAC__
|
||||
#undef HAVE_LIBNTFS
|
||||
#undef HAVE_LIBNTFS3G
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_LIBNTFS) || defined(HAVE_LIBNTFS3G)
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _NTFSP_H
|
||||
#define _NTFSP_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ unsigned int ntfs_remove_used_space(disk_t *disk_car,const partition_t *partitio
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTAUTO_H
|
||||
#define _PARTAUTO_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -33,3 +35,4 @@ void autodetect_arch(disk_t *disk, const arch_fnct_t *arch);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTGPTN_H
|
||||
#define _PARTGPTN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_gpt_ncurses(disk_t *disk, list_part_t *list_part);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTHUMAX_H
|
||||
#define _PARTHUMAX_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_humax_cli(const disk_t *disk_car,list_part_t *list_pa
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTI386_H
|
||||
#define _PARTI386_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -51,3 +53,4 @@ int recover_i386_logical(disk_t *disk, const unsigned char *buffer, partition_t
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTI386N_H
|
||||
#define _PARTI386N_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_i386_ncurses(disk_t *disk, list_part_t *list_part);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTMAC_H
|
||||
#define _PARTMAC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -98,3 +100,4 @@ list_part_t *add_partition_mac_cli(disk_t *disk_car,list_part_t *list_part, char
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTMACN_H
|
||||
#define _PARTMACN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -30,3 +32,4 @@ list_part_t *add_partition_mac_ncurses(disk_t *disk, list_part_t *list_part);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTSUN_H
|
||||
#define _PARTSUN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_sun_cli(const disk_t *disk_car,list_part_t *list_part
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTSUNN_H
|
||||
#define _PARTSUNN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_sun_ncurses(disk_t *disk, list_part_t *list_part);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTXBOX_H
|
||||
#define _PARTXBOX_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -36,3 +38,4 @@ list_part_t *add_partition_xbox_cli(const disk_t *disk_car,list_part_t *list_par
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PARTXBOXN_H
|
||||
#define _PARTXBOXN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ list_part_t *add_partition_xbox_ncurses(disk_t *disk, list_part_t *list_part);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PBLOCKSIZE_H
|
||||
#define _PBLOCKSIZE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void menu_choose_blocksize(unsigned int *blocksize, uint64_t *offset, const unsi
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,7 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _PDISKSEL_H
|
||||
#define _PDISKSEL_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -29,3 +30,4 @@ disk_t *photorec_disk_selection_cli(const char *cmd_device, const list_disk_t *l
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PDISKSELN_H
|
||||
#define _PDISKSELN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -36,3 +38,4 @@ int do_curses_photorec(struct ph_param *params, struct ph_options *options, cons
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PFREE_WHOLE_H
|
||||
#define _PFREE_WHOLE_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ int ask_mode_ext2(const disk_t *disk_car, const partition_t *partition, unsigned
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,11 +19,15 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHBF_H
|
||||
#define _PHBF_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
pstatus_t photorec_bf(struct ph_param *params, const struct ph_options *options, alloc_data_t *list_search_space);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,11 +19,15 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHBS_H
|
||||
#define _PHBS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
pstatus_t photorec_find_blocksize(struct ph_param *params, const struct ph_options *options, alloc_data_t *list_search_space);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
24
src/phcfg.h
24
src/phcfg.h
|
@ -1,3 +1,26 @@
|
|||
/*
|
||||
|
||||
File: phcfg.h
|
||||
|
||||
Copyright (C) 2020 Christophe GRENIER <grenier@cgsecurity.org>
|
||||
|
||||
This software 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 the Free Software Foundation, Inc., 51
|
||||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHCFG_H
|
||||
#define _PHCFG_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -9,3 +32,4 @@ int file_options_load(file_enable_t *files_enable);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHCLI_H
|
||||
#define _PHCLI_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -34,3 +36,4 @@ int menu_photorec_cli(list_part_t *list_part, struct ph_param *params, struct ph
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _PHNC_H
|
||||
#define _PHNC_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -35,4 +38,4 @@ pstatus_t photorec_progressbar(WINDOW *window, const unsigned int pass, const st
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHOTOREC_CHECK_HEADER_H
|
||||
#define _PHOTOREC_CHECK_HEADER_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -175,3 +177,4 @@ inline static pstatus_t photorec_check_header(file_recovery_t *file_recovery, st
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PHRECN_H
|
||||
#define _PHRECN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -32,3 +34,4 @@ void interface_options_photorec_ncurses(struct ph_options *options);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PNEXT_H
|
||||
#define _PNEXT_H
|
||||
|
||||
/* #define DEBUG_GET_NEXT_SECTOR */
|
||||
static
|
||||
|
@ -90,3 +92,4 @@ static inline void get_prev_sector(const alloc_data_t *list_search_space, alloc_
|
|||
else
|
||||
get_prev_header(list_search_space, current_search_space, offset, blocksize);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _POPTIONS_H
|
||||
#define _POPTIONS_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -39,3 +42,4 @@ void interface_options_photorec_log(const struct ph_options *options);
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PPARTSELN_H
|
||||
#define _PPARTSELN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ void menu_photorec(struct ph_param *params, struct ph_options *options, alloc_da
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -1,3 +1,27 @@
|
|||
/*
|
||||
|
||||
File: psearch.h
|
||||
|
||||
Copyright (C) 2020 Christophe GRENIER <grenier@cgsecurity.org>
|
||||
|
||||
This software 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 the Free Software Foundation, Inc., 51
|
||||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PSEARCH_H
|
||||
#define _PSEARCH_H
|
||||
|
||||
static inline alloc_data_t *file_add_data(alloc_data_t *data, const uint64_t offset, const unsigned int content)
|
||||
{
|
||||
if(!(data->start <= offset && offset <= data->end))
|
||||
|
@ -57,4 +81,4 @@ static inline int ind_block(const unsigned char *buffer, const unsigned int bloc
|
|||
return 1; /* Ok: ind_block points to non-fragmented block */
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
*/
|
||||
#ifndef _PSEARCHN_H
|
||||
#define _PSEARCHN_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -28,3 +30,4 @@ pstatus_t photorec_aux(struct ph_param *params, const struct ph_options *options
|
|||
#ifdef __cplusplus
|
||||
} /* closing brace for extern "C" */
|
||||
#endif
|
||||
#endif
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue