summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPali Rohár <pali.rohar@gmail.com>2012-06-23 21:26:30 +0200
committerPali Rohár <pali.rohar@gmail.com>2012-06-23 21:26:30 +0200
commit2421b9f6c250e1a20ec75c9b541a5142485e579d (patch)
tree9548efa89e7543dc029daf48016a2ad108b07099
parenteac07b18d9bca9af60bf81dda0df27dea475cc72 (diff)
download0xFFFF-2421b9f6c250e1a20ec75c9b541a5142485e579d.tar.bz2
fiasco - remove dead code
-rw-r--r--src/fiasco.c43
-rw-r--r--src/main.h1
2 files changed, 0 insertions, 44 deletions
diff --git a/src/fiasco.c b/src/fiasco.c
index d3b323d..0f6f8b2 100644
--- a/src/fiasco.c
+++ b/src/fiasco.c
@@ -389,18 +389,6 @@ int fiasco_new(const char *filename, const char *swver)
return fd;
}
-int fiasco_add_eof(int fd)
-{
-#if 0
- unsigned char buf[120];
- if (fd == -1)
- return -1;
- memset(buf,'\xff', 120);
- write(fd, buf, 120);
-#endif
- return 0;
-}
-
int fiasco_add(int fd, const char *name, const char *file, const char *layout, const char *device, const char *hwrevs, const char *version)
{
int i;
@@ -643,38 +631,7 @@ int fiasco_pack(int optind, char *argv[])
return 1;
}
}
- fiasco_add_eof(fd);
printf("Done!\n");
close(fd);
return 0;
}
-
-/* local code */
-#if 0
-void my_callback(int fd, struct header_t *header)
-{
- fiasco_data_read(header);
- //read(fd, buf, header->size);
- printf("Dumping %s\n", header->name);
- printf("DATA: %02x\n", header->data[0]);
- fiasco_data_free(header);
-}
-
-int main(int argc, char **argv)
-{
- if (argc!=2) {
- printf("Usage: unfiasco [file]\n");
- return 1;
- }
-
-/*
- fd = fiasco_new("myfiasco", "pancake-edition");
- fiasco_add(fd, "kernel", "zImage", "2.6.22");
- close(fd);
-*/
-
-// fiasco_callback = &my_callback;
-
- return openfiasco(argv[1]);
-}
-#endif
diff --git a/src/main.h b/src/main.h
index ba31720..d5a5d20 100644
--- a/src/main.h
+++ b/src/main.h
@@ -122,7 +122,6 @@ extern char *root_devices[];
int openfiasco(const char *name, const char *type, const char *device, const char *hwrev, const char *version, int v);
int fiasco_new(const char *filename, const char *name);
void fiasco_data_read(struct header_t *header);
-int fiasco_add_eof(int fd);
extern int (*fiasco_callback)(struct header_t *header);
int fiasco_add(int fd, const char *name, const char *file, const char *layout, const char *device, const char *hwrevs, const char *version);
int fiasco_pack(int optind, char *argv[]);