9 #include "mspack/macros.h"
15 #define BUF_SIZE (1024*4096)
19 static unsigned int counter = 1;
27 }
while (
stat(outname, &st_buf) == 0);
29 printf(
"ripping %s offset %" LD " length %u to %s\n",
32 if (!(
in = fopen(
fname,
"rb"))) {
36 if (!(
out = fopen(outname,
"wb"))) {
41 fprintf(stderr,
"%s: can't seek to cab offset %"LD"\n",
fname,
offset);
46 size_t actual = fread(&
buf[0], 1,
run,
in);
48 fprintf(stderr,
"%s: file %u bytes shorter than expected\n",
76 for (
c = cab;
c;
c =
c->next) {
const lzma_allocator const uint8_t * in
const lzma_allocator const uint8_t size_t uint8_t * out
int main(int argc, char *argv[])
void rip(char *fname, off_t offset, unsigned int length)
_Use_decl_annotations_ int __cdecl printf(const char *const _Format,...)
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len static semflg const void static shmflg const struct timespec struct timespec static rem const char static group const void length
static static fork const void static count static fd const char const char static newpath char char argv
static int run(int i, const char *arg)
struct mscabd_cabinet *(* search)(struct mscab_decompressor *self, const char *filename)
void(* close)(struct mscab_decompressor *self, struct mscabd_cabinet *cab)
int(* set_param)(struct mscab_decompressor *self, int param, int value)