1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-16 16:19:10 +00:00
Interlisp.maiko/inc/lispver1.h
Nick Briggs a093d80fa5
Add include guards to all the include files in inc/ which were missing them. (#189)
As a prerequisite for cleaning up some other include issues, all the
include files in inc/ should have an include guard.  All the xxxdefs.h
were created with them, but most older files were not.
2021-01-07 03:06:42 +00:00

48 lines
1.1 KiB
C

#ifndef LISPVER1_H
#define LISPVER1_H 1
/* $Id: lispver1.h,v 1.2 1999/01/03 02:06:08 sybalsky Exp $ (C) Copyright Venue, All Rights Reserved */
/* DOS version of LispVersionToUnixVersion */
#define LispVersionToUnixVersion(pathname, ver) \
{ \
\
register char *cp; \
register char *vp; \
char ver_buf[VERSIONLEN]; \
\
cp = pathname; \
vp = NULL; \
while (*cp) \
{ \
switch (*cp) \
{ \
\
case ';': \
*cp = 0; \
cp++; \
vp = cp; \
break; \
\
case '\'': \
if (*(cp + 1) != 0) cp += 2; \
else cp++; \
break; \
\
default: \
cp++; \
break; \
} \
} \
\
if (vp) \
{ \
NumericStringP(vp, YES, NO); \
NO: *vp = 0; \
YES: \
if ((*vp)) ver = atoi(vp); \
else ver = -1; \
} \
else ver = -1; \
}
#endif /* LISPVER1_H */