mirror of
https://github.com/aaru-dps/libaaruformat.git
synced 2025-12-16 11:14:39 +00:00
Update all calls to aaruf_open.
This commit is contained in:
@@ -44,7 +44,7 @@ int cli_compare(const char *path1, const char *path2, bool use_long)
|
||||
uint8_t sector_status2 = 0;
|
||||
|
||||
printf("Opening first image: %s\n", path1);
|
||||
ctx1 = aaruf_open(path1);
|
||||
ctx1 = aaruf_open(path1, false, NULL);
|
||||
if(ctx1 == NULL)
|
||||
{
|
||||
fprintf(stderr, "Error: Could not open first image '%s'\n", path1);
|
||||
@@ -52,7 +52,7 @@ int cli_compare(const char *path1, const char *path2, bool use_long)
|
||||
}
|
||||
|
||||
printf("Opening second image: %s\n", path2);
|
||||
ctx2 = aaruf_open(path2);
|
||||
ctx2 = aaruf_open(path2, false, NULL);
|
||||
if(ctx2 == NULL)
|
||||
{
|
||||
fprintf(stderr, "Error: Could not open second image '%s'\n", path2);
|
||||
|
||||
@@ -417,7 +417,7 @@ int compare(const char *path1, const char *path2)
|
||||
// Open first image
|
||||
tb_printf(2, 2, TB_WHITE | TB_BOLD, TB_BLUE, "Opening image...");
|
||||
tb_present();
|
||||
ctx1 = aaruf_open(path1);
|
||||
ctx1 = aaruf_open(path1, false, NULL);
|
||||
if(ctx1 == NULL)
|
||||
{
|
||||
tb_printf(2, 3, TB_RED | TB_BOLD, TB_BLUE, "Error opening image");
|
||||
@@ -430,7 +430,7 @@ int compare(const char *path1, const char *path2)
|
||||
// Open second image
|
||||
tb_printf(state.mid_x + 2, 2, TB_WHITE | TB_BOLD, TB_BLUE, "Opening image...");
|
||||
tb_present();
|
||||
ctx2 = aaruf_open(path2);
|
||||
ctx2 = aaruf_open(path2, false, NULL);
|
||||
if(ctx2 == NULL)
|
||||
{
|
||||
tb_printf(state.mid_x + 2, 3, TB_RED | TB_BOLD, TB_BLUE, "Error opening image");
|
||||
|
||||
@@ -41,7 +41,7 @@ int convert(const char *input_path, const char *output_path, bool use_long)
|
||||
printf("Converting image from %s to %s%s...\n", input_path, output_path, use_long ? " (long mode)" : "");
|
||||
|
||||
// Open input image
|
||||
input_ctx = aaruf_open(input_path);
|
||||
input_ctx = aaruf_open(input_path, false, NULL);
|
||||
if(input_ctx == NULL)
|
||||
{
|
||||
printf("Error %d when opening input AaruFormat image.\n", errno);
|
||||
|
||||
@@ -76,7 +76,7 @@ int info(const char *path)
|
||||
mediaTagEntry const *mediaTag = NULL;
|
||||
mediaTagEntry const *tmpMediaTag = NULL;
|
||||
|
||||
ctx = aaruf_open(path);
|
||||
ctx = aaruf_open(path, false, NULL);
|
||||
|
||||
if(ctx == NULL)
|
||||
{
|
||||
|
||||
@@ -32,7 +32,7 @@ int read(const unsigned long long sector_no, const char *path)
|
||||
uint8_t *data = NULL;
|
||||
uint8_t sector_status = 0;
|
||||
|
||||
ctx = aaruf_open(path);
|
||||
ctx = aaruf_open(path, false, NULL);
|
||||
|
||||
if(ctx == NULL)
|
||||
{
|
||||
@@ -85,7 +85,7 @@ int read_long(const unsigned long long sector_no, const char *path)
|
||||
uint8_t *data = NULL;
|
||||
uint8_t sector_status = 0;
|
||||
|
||||
ctx = aaruf_open(path);
|
||||
ctx = aaruf_open(path, false, NULL);
|
||||
|
||||
if(ctx == NULL)
|
||||
{
|
||||
|
||||
@@ -29,7 +29,7 @@ int verify(const char *path)
|
||||
aaruformat_context *ctx = NULL;
|
||||
uint32_t res = 0;
|
||||
|
||||
ctx = aaruf_open(path);
|
||||
ctx = aaruf_open(path, false, NULL);
|
||||
|
||||
if(ctx == NULL)
|
||||
{
|
||||
@@ -56,7 +56,7 @@ int verify_sectors(const char *path)
|
||||
uint32_t buffer_len = 2352;
|
||||
int32_t res = 0;
|
||||
CdEccContext *cd_ecc_context = NULL;
|
||||
ctx = aaruf_open(path);
|
||||
ctx = aaruf_open(path, false, NULL);
|
||||
bool verify_result = false;
|
||||
bool has_edc = false, has_ecc_p = false, ecc_p_correct = false, has_ecc_q = false, ecc_q_correct = false;
|
||||
bool edc_correct = false;
|
||||
|
||||
Reference in New Issue
Block a user