* version.h doesn't need an RCS ID
* compat.h does, add it to misc.c, always include it, move if NEED_COMPAT * major whitespace cleanup in sh.h
This commit is contained in:
parent
e20d82c4d1
commit
a87ff74cbd
9
compat.h
9
compat.h
@ -1,5 +1,6 @@
|
|||||||
/* $MirOS: src/bin/mksh/compat.h,v 1.3 2006/08/18 18:59:49 tg Exp $ */
|
#define MKSH_COMPAT_H_ID "$MirOS: src/bin/mksh/compat.h,v 1.4 2006/08/22 22:16:04 tg Exp $"
|
||||||
|
|
||||||
|
#ifdef NEED_COMPAT
|
||||||
/* Part I: extra headers */
|
/* Part I: extra headers */
|
||||||
|
|
||||||
#if defined(__sun__) || defined(__INTERIX)
|
#if defined(__sun__) || defined(__INTERIX)
|
||||||
@ -39,7 +40,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef S_ISTXT
|
#ifndef S_ISTXT
|
||||||
#define S_ISTXT 0001000 /* sticky bit */
|
#define S_ISTXT 0001000
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
@ -60,8 +61,10 @@ mode_t getmode(const void *, mode_t);
|
|||||||
void *setmode(const char *);
|
void *setmode(const char *);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(__INTERIX)
|
#ifdef __INTERIX
|
||||||
#define makedev(x,y) mkdev((x),(y))
|
#define makedev(x,y) mkdev((x),(y))
|
||||||
extern int __cdecl seteuid(uid_t);
|
extern int __cdecl seteuid(uid_t);
|
||||||
extern int __cdecl setegid(gid_t);
|
extern int __cdecl setegid(gid_t);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
4
misc.c
4
misc.c
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
#include "sh.h"
|
#include "sh.h"
|
||||||
|
|
||||||
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.13 2006/08/09 20:44:15 tg Exp $"
|
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.14 2006/08/22 22:16:04 tg Exp $"
|
||||||
"\t" MKSH_SH_H_ID);
|
"\t" MKSH_SH_H_ID "\t" MKSH_COMPAT_H_ID);
|
||||||
|
|
||||||
short chtypes[UCHAR_MAX+1]; /* type bits for unsigned char */
|
short chtypes[UCHAR_MAX+1]; /* type bits for unsigned char */
|
||||||
|
|
||||||
|
11
sh.h
11
sh.h
@ -8,7 +8,7 @@
|
|||||||
/* $OpenBSD: c_test.h,v 1.4 2004/12/20 11:34:26 otto Exp $ */
|
/* $OpenBSD: c_test.h,v 1.4 2004/12/20 11:34:26 otto Exp $ */
|
||||||
/* $OpenBSD: tty.h,v 1.5 2004/12/20 11:34:26 otto Exp $ */
|
/* $OpenBSD: tty.h,v 1.5 2004/12/20 11:34:26 otto Exp $ */
|
||||||
|
|
||||||
#define MKSH_SH_H_ID "$MirOS: src/bin/mksh/sh.h,v 1.35 2006/08/16 00:00:24 tg Exp $"
|
#define MKSH_SH_H_ID "$MirOS: src/bin/mksh/sh.h,v 1.36 2006/08/22 22:16:04 tg Exp $"
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
|
|
||||||
@ -44,9 +44,8 @@
|
|||||||
#include <termios.h>
|
#include <termios.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#if defined(NEED_COMPAT)
|
|
||||||
#include "compat.h"
|
#include "compat.h"
|
||||||
#endif
|
#include "version.h"
|
||||||
|
|
||||||
/* some useful #defines */
|
/* some useful #defines */
|
||||||
#ifdef EXTERN
|
#ifdef EXTERN
|
||||||
@ -560,7 +559,6 @@ struct arg_info {
|
|||||||
*/
|
*/
|
||||||
struct block {
|
struct block {
|
||||||
Area area; /* area to allocate things */
|
Area area; /* area to allocate things */
|
||||||
/*struct arg_info argi;*/
|
|
||||||
char **argv;
|
char **argv;
|
||||||
int argc;
|
int argc;
|
||||||
int flags; /* see BF_* */
|
int flags; /* see BF_* */
|
||||||
@ -1141,8 +1139,7 @@ int getn(const char *, int *);
|
|||||||
int bi_getn(const char *, int *);
|
int bi_getn(const char *, int *);
|
||||||
int gmatchx(const char *, const char *, int);
|
int gmatchx(const char *, const char *, int);
|
||||||
int has_globbing(const char *, const char *);
|
int has_globbing(const char *, const char *);
|
||||||
const unsigned char *pat_scan(const unsigned char *, const unsigned char *,
|
const unsigned char *pat_scan(const unsigned char *, const unsigned char *, int);
|
||||||
int);
|
|
||||||
void qsortp(void **, size_t, int (*)(void *, void *));
|
void qsortp(void **, size_t, int (*)(void *, void *));
|
||||||
int xstrcmp(void *, void *);
|
int xstrcmp(void *, void *);
|
||||||
void ksh_getopt_reset(Getopt *, int);
|
void ksh_getopt_reset(Getopt *, int);
|
||||||
@ -1270,8 +1267,6 @@ EXTERN struct termios tty_state; /* saved tty state */
|
|||||||
extern void tty_init(int);
|
extern void tty_init(int);
|
||||||
extern void tty_close(void);
|
extern void tty_close(void);
|
||||||
|
|
||||||
#include "version.h"
|
|
||||||
|
|
||||||
/* be sure not to interfere with anyone else's idea about EXTERN */
|
/* be sure not to interfere with anyone else's idea about EXTERN */
|
||||||
#ifdef EXTERN_DEFINED
|
#ifdef EXTERN_DEFINED
|
||||||
# undef EXTERN_DEFINED
|
# undef EXTERN_DEFINED
|
||||||
|
Loading…
x
Reference in New Issue
Block a user