source: rtems/cpukit/libmisc/untar/untar.h @ 1996aee7

4.104.114.84.95
Last change on this file since 1996aee7 was 1996aee7, checked in by Ralf Corsepius <ralf.corsepius@…>, on Feb 7, 2005 at 1:25:14 PM

2005-02-07 Ralf Corsepius <ralf.corsepius@…>

  • libfs/src/imfs/imfs.h, libfs/src/imfs/imfs_load_tar.c, libmisc/untar/untar.c, libmisc/untar/untar.h: Various generalizations and fixes.
  • Property mode set to 100644
File size: 1.3 KB
Line 
1/*
2 *  Written by: Jake Janovetz <janovetz@tempest.ece.uiuc.edu>
3 *
4 *  The license and distribution terms for this file may be
5 *  found in the file LICENSE in this distribution or at
6 *  http://www.rtems.com/license/LICENSE.
7 *
8 *  $Id$
9 */
10
11#ifndef __UNTAR_H__
12#define __UNTAR_H__
13
14#include <stddef.h>
15#include <rtems/tar.h>
16
17#ifdef __cplusplus
18extern "C" {
19#endif
20
21#define UNTAR_SUCCESSFUL         0
22#define UNTAR_FAIL               1
23#define UNTAR_INVALID_CHECKSUM   2
24#define UNTAR_INVALID_HEADER     3
25
26
27int Untar_FromMemory(char *tar_buf, size_t size);
28int Untar_FromFile(char *tar_name);
29
30/**************************************************************************
31 * This converts octal ASCII number representations into an
32 * unsigned long.  Only support 32-bit numbers for now.
33 *************************************************************************/
34extern unsigned long
35_rtems_octal2ulong(const char *octascii, size_t len);
36
37/************************************************************************
38 * Compute the TAR checksum and check with the value in
39 * the archive.  The checksum is computed over the entire
40 * header, but the checksum field is substituted with blanks.
41 ************************************************************************/
42extern int
43_rtems_tar_header_checksum(const char *bufr);
44
45#ifdef __cplusplus
46}
47#endif
48
49#endif  /* __UNTAR_H__ */
Note: See TracBrowser for help on using the repository browser.