~ubuntu-branches/ubuntu/precise/arj/precise-security

« back to all changes in this revision

Viewing changes to arjtypes.h

  • Committer: Bazaar Package Importer
  • Author(s): Guillem Jover
  • Date: 2004-06-27 08:07:09 UTC
  • Revision ID: james.westby@ubuntu.com-20040627080709-1gkxm72ex66gkwe4
Tags: upstream-3.10.21
ImportĀ upstreamĀ versionĀ 3.10.21

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * $Id: arjtypes.h,v 1.1.1.1 2002/03/28 00:01:28 andrew_belov Exp $
 
3
 * ---------------------------------------------------------------------------
 
4
 * OS-independent types are to be declared here.
 
5
 *
 
6
 */
 
7
 
 
8
#ifndef ARJTYPES_INCLUDED
 
9
#define ARJTYPES_INCLUDED
 
10
 
 
11
/* Message classes */
 
12
 
 
13
#ifdef FMSG_ST
 
14
typedef char FAR FMSG;
 
15
typedef FMSG * FAR FMSGP;
 
16
typedef FMSG * FAR NMSGP;
 
17
#else
 
18
typedef char FMSG;
 
19
typedef char *FMSGP;
 
20
typedef char *NMSGP;
 
21
#endif
 
22
 
 
23
/* File access mode record */
 
24
 
 
25
struct file_mode
 
26
{
 
27
 int dos;                               /* For internals of ARJ (-hb, etc.) */
 
28
 int native;
 
29
};
 
30
 
 
31
/* Timestamp record */
 
32
 
 
33
struct timestamp
 
34
{
 
35
 unsigned long dos;                     /* Local */
 
36
 unsigned long unixtime;                /* GMT */
 
37
};
 
38
 
 
39
/* A handy macro for verifying the validity of timestamps */
 
40
 
 
41
#define ts_valid(t) (t.dos!=0L)
 
42
 
 
43
/* Prototypes */
 
44
 
 
45
void fm_store(struct file_mode *dest, int host_os, int mode);
 
46
unsigned int fm_native(struct file_mode *fm, int host_os);
 
47
void ts_store(struct timestamp *dest, int host_os, unsigned long value);
 
48
unsigned long ts_native(struct timestamp *ts, int host_os);
 
49
int ts_cmp(struct timestamp *ts1, struct timestamp *ts2);
 
50
void make_timestamp(struct timestamp *dest, int y, int m, int d, int hh, int mm, int ss);
 
51
void timestamp_to_str(char *str, struct timestamp *ts);
 
52
 
 
53
#endif