get_header_tar_lzma.c 589 B

12345678910111213141516171819202122
  1. /* vi: set sw=4 ts=4: */
  2. /*
  3. * Small lzma deflate implementation.
  4. * Copyright (C) 2006 Aurelien Jacobs <aurel@gnuage.org>
  5. *
  6. * Licensed under GPL v2, see file LICENSE in this tarball for details.
  7. */
  8. #include "unarchive.h"
  9. char get_header_tar_lzma(archive_handle_t * archive_handle)
  10. {
  11. /* Can't lseek over pipes */
  12. archive_handle->seek = seek_by_read;
  13. archive_handle->src_fd = open_transformer(archive_handle->src_fd, unlzma);
  14. archive_handle->offset = 0;
  15. while (get_header_tar(archive_handle) == EXIT_SUCCESS) /**/;
  16. /* Can only do one file at a time */
  17. return EXIT_FAILURE;
  18. }