be

based editor
git clone git://git.kocotian.pl/be.git
Log | Files | Refs | README | LICENSE

commit 00cb47b13144eb6bb121da3b528c8add7135f855
parent 46f6c7d72916fb1581d2cdf098bef224c8b4a5eb
Author: kocotian <kocotian@kocotian.pl>
Date:   Sun, 18 Apr 2021 12:03:10 +0200

Multiplatform limits, fixed none-modifier

Diffstat:
Mbe.c | 13++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/be.c b/be.c @@ -19,7 +19,15 @@ #include <ctype.h> #include <errno.h> +#ifdef __linux__ #include <linux/limits.h> +#elif __FreeBSD__ +#include <sys/syslimits.h> +#elif __OpenBSD__ +#include <limits.h> +#else +#define UNLIMITED +#endif #include <stdio.h> #include <stdlib.h> #include <sys/ioctl.h> @@ -30,10 +38,13 @@ #include <util.h> #define CURBUF(EDITOR) ((EDITOR).bufs.data[(EDITOR).curbuf]) +#ifdef UNLIMITED +#define PATH_MAX 1024 +#endif /* types */ typedef enum Mod { - ModNone = 0, ModControl = 0x1f, ModShift = 0xdf, + ModNone = 0xff, ModControl = 0x1f, ModShift = 0xdf, } Mod; typedef union Arg {