fixup “\builtin” on OS/2; thanks komh for spotting this
This commit is contained in:
8
exec.c
8
exec.c
@ -23,7 +23,7 @@
|
|||||||
|
|
||||||
#include "sh.h"
|
#include "sh.h"
|
||||||
|
|
||||||
__RCSID("$MirOS: src/bin/mksh/exec.c,v 1.190 2017/03/12 02:04:12 tg Exp $");
|
__RCSID("$MirOS: src/bin/mksh/exec.c,v 1.191 2017/03/22 00:20:51 tg Exp $");
|
||||||
|
|
||||||
#ifndef MKSH_DEFAULT_EXECSHELL
|
#ifndef MKSH_DEFAULT_EXECSHELL
|
||||||
#define MKSH_DEFAULT_EXECSHELL MKSH_UNIXROOT "/bin/sh"
|
#define MKSH_DEFAULT_EXECSHELL MKSH_UNIXROOT "/bin/sh"
|
||||||
@ -1135,7 +1135,11 @@ findcom(const char *name, int flags)
|
|||||||
char *fpath;
|
char *fpath;
|
||||||
union mksh_cchack npath;
|
union mksh_cchack npath;
|
||||||
|
|
||||||
if (mksh_vdirsep(name)) {
|
if (mksh_vdirsep(name)
|
||||||
|
#ifdef __OS2__
|
||||||
|
&& (strcmp(name, T_builtin) != 0)
|
||||||
|
#endif
|
||||||
|
) {
|
||||||
insert = 0;
|
insert = 0;
|
||||||
/* prevent FPATH search below */
|
/* prevent FPATH search below */
|
||||||
flags &= ~FC_FUNC;
|
flags &= ~FC_FUNC;
|
||||||
|
6
sh.h
6
sh.h
@ -175,9 +175,9 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef EXTERN
|
#ifdef EXTERN
|
||||||
__RCSID("$MirOS: src/bin/mksh/sh.h,v 1.796 2017/03/19 22:31:29 tg Exp $");
|
__RCSID("$MirOS: src/bin/mksh/sh.h,v 1.797 2017/03/22 00:20:53 tg Exp $");
|
||||||
#endif
|
#endif
|
||||||
#define MKSH_VERSION "R54 2017/03/19"
|
#define MKSH_VERSION "R54 2017/03/21"
|
||||||
|
|
||||||
/* arithmetic types: C implementation */
|
/* arithmetic types: C implementation */
|
||||||
#if !HAVE_CAN_INTTYPES
|
#if !HAVE_CAN_INTTYPES
|
||||||
@ -865,6 +865,7 @@ EXTERN const char Tbad_bsize[] E_INIT("bad shf/buf/bsize");
|
|||||||
EXTERN const char Tbad_sig_ss[] E_INIT("%s: bad signal '%s'");
|
EXTERN const char Tbad_sig_ss[] E_INIT("%s: bad signal '%s'");
|
||||||
#define Tbad_sig_s (Tbad_sig_ss + 4)
|
#define Tbad_sig_s (Tbad_sig_ss + 4)
|
||||||
EXTERN const char T__builtin[] E_INIT("-\\builtin");
|
EXTERN const char T__builtin[] E_INIT("-\\builtin");
|
||||||
|
#define T_builtin (T__builtin + 1)
|
||||||
#define Tbuiltin (T__builtin + 2)
|
#define Tbuiltin (T__builtin + 2)
|
||||||
EXTERN const char Toomem[] E_INIT("can't allocate %zu data bytes");
|
EXTERN const char Toomem[] E_INIT("can't allocate %zu data bytes");
|
||||||
EXTERN const char Tcant_cd[] E_INIT("restricted shell - can't cd");
|
EXTERN const char Tcant_cd[] E_INIT("restricted shell - can't cd");
|
||||||
@ -1012,6 +1013,7 @@ EXTERN const char T_devtty[] E_INIT("/dev/tty");
|
|||||||
#define Tbad_sig_ss "%s: bad signal '%s'"
|
#define Tbad_sig_ss "%s: bad signal '%s'"
|
||||||
#define Tbad_sig_s "bad signal '%s'"
|
#define Tbad_sig_s "bad signal '%s'"
|
||||||
#define T__builtin "-\\builtin"
|
#define T__builtin "-\\builtin"
|
||||||
|
#define T_builtin "\\builtin"
|
||||||
#define Tbuiltin "builtin"
|
#define Tbuiltin "builtin"
|
||||||
#define Toomem "can't allocate %zu data bytes"
|
#define Toomem "can't allocate %zu data bytes"
|
||||||
#define Tcant_cd "restricted shell - can't cd"
|
#define Tcant_cd "restricted shell - can't cd"
|
||||||
|
Reference in New Issue
Block a user