Add example test program and some changes to make it work
This commit is contained in:
@ -7,8 +7,8 @@
|
||||
#include <assert.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <libburn.h>
|
||||
#include <libisofs.h>
|
||||
#include <libburn/libburn.h>
|
||||
#include <libisofs/libisofs.h>
|
||||
#include "isoburn.h"
|
||||
|
||||
struct disc_data_src {
|
||||
@ -31,9 +31,10 @@ ds_read_block(struct data_source *src, int lba, unsigned char *buffer)
|
||||
* return BLOCK_OUT_OF_FILE;
|
||||
*/
|
||||
|
||||
ret = burn_read_data(data->d, (off_t) lba * (off_t) 2048, buffer, 2048, &count, 0);
|
||||
ret = burn_read_data(data->d, (off_t) lba * (off_t) 2048, (char *) buffer,
|
||||
2048, &count, 0);
|
||||
if (ret <= 0 )
|
||||
return -1; //error
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
@ -55,7 +56,7 @@ ds_free_data(struct data_source *src)
|
||||
free(src->data);
|
||||
}
|
||||
|
||||
static struct data_source *
|
||||
struct data_source *
|
||||
isoburn_data_source_new(struct burn_drive *d)
|
||||
{
|
||||
struct disc_data_src *data;
|
||||
|
Reference in New Issue
Block a user