Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
08a74503
Commit
08a74503
authored
22 years ago
by
rswindell
Browse files
Options
Downloads
Patches
Plain Diff
Moved to xpdev directory.
parent
6aeaae4f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/sbbs3/gen_defs.h
+0
-180
0 additions, 180 deletions
src/sbbs3/gen_defs.h
with
0 additions
and
180 deletions
src/sbbs3/gen_defs.h
deleted
100644 → 0
+
0
−
180
View file @
6aeaae4f
/* gen_defs.h */
/* General(ly useful) constant, macro, and type definitions */
/* $Id$ */
/****************************************************************************
* @format.tab-size 4 (Plain Text/Source Code File Header) *
* @format.use-tabs true (see http://www.synchro.net/ptsc_hdr.html) *
* *
* Copyright 2000 Rob Swindell - http://www.synchro.net/copyright.html *
* *
* This program is free software; you can redistribute it and/or *
* modify it under the terms of the GNU General Public License *
* as published by the Free Software Foundation; either version 2 *
* of the License, or (at your option) any later version. *
* See the GNU General Public License for more details: gpl.txt or *
* http://www.fsf.org/copyleft/gpl.html *
* *
* Anonymous FTP access to the most recent released source is available at *
* ftp://vert.synchro.net, ftp://cvs.synchro.net and ftp://ftp.synchro.net *
* *
* Anonymous CVS access to the development source and modification history *
* is available at cvs.synchro.net:/cvsroot/sbbs, example: *
* cvs -d :pserver:anonymous@cvs.synchro.net:/cvsroot/sbbs login *
* (just hit return, no password is necessary) *
* cvs -d :pserver:anonymous@cvs.synchro.net:/cvsroot/sbbs checkout src *
* *
* For Synchronet coding style and modification guidelines, see *
* http://www.synchro.net/source.html *
* *
* You are encouraged to submit any modifications (preferably in Unix diff *
* format) via e-mail to mods@synchro.net *
* *
* Note: If this box doesn't appear square, then you need to fix your tabs. *
****************************************************************************/
#ifndef _GEN_DEFS_H
#define _GEN_DEFS_H
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
/* Don't bring in excess baggage */
#include
<windows.h>
#endif
#include
<sys/types.h>
/* Control characters */
#define STX 0x02
/* Start of text ^B */
#define ETX 0x03
/* End of text ^C */
#define BEL 0x07
/* Bell/beep ^G */
#define FF 0x0c
/* Form feed ^L */
#define ESC 0x1b
/* Escape ^[ */
#define DEL 0x7f
/* Delete ^BS */
#define BS '\b'
/* Back space ^H */
#define TAB '\t'
/* Horizontal tabulation ^I */
#define LF '\n'
/* Line feed ^J */
#define CR '\r'
/* Carriage return ^M */
#define SP ' '
/* Space */
enum
{
CTRL_A
=
1
,
CTRL_B
,
CTRL_C
,
CTRL_D
,
CTRL_E
,
CTRL_F
,
CTRL_G
,
CTRL_H
,
CTRL_I
,
CTRL_J
,
CTRL_K
,
CTRL_L
,
CTRL_M
,
CTRL_N
,
CTRL_O
,
CTRL_P
,
CTRL_Q
,
CTRL_R
,
CTRL_S
,
CTRL_T
,
CTRL_U
,
CTRL_V
,
CTRL_W
,
CTRL_X
,
CTRL_Y
,
CTRL_Z
};
#ifndef MAX_PATH
#ifdef MAXPATHLEN
#define MAX_PATH MAXPATHLEN
/* clib.h */
#elif defined PATH_MAX
#define MAX_PATH PATH_MAX
#elif defined _MAX_PATH
#define MAX_PATH _MAX_PATH
#else
#define MAX_PATH 260
#endif
#endif
/* Unsigned type short-hands */
#ifndef uchar
#define uchar unsigned char
#endif
#ifndef __GLIBC__
#ifndef ushort
#define ushort unsigned short
#define uint unsigned int
#define ulong unsigned long
#endif
#endif
/* Windows Types */
#ifndef BYTE
#define BYTE uchar
#endif
#ifndef WORD
#define WORD ushort
#endif
#ifndef DWORD
#define DWORD ulong
#endif
#ifndef BOOL
#define BOOL int
#endif
#ifndef TRUE
#define TRUE 1
#define FALSE 0
#endif
#ifndef HANDLE
#define HANDLE void*
#endif
#define SAFECOPY(dst,src) sprintf(dst,"%.*s",sizeof(dst)-1,src)
/****************************************************************************/
/* MALLOC/FREE Macros for various compilers and environments */
/* MALLOC is used for allocations of 64k or less */
/* FREE is used to free buffers allocated with MALLOC */
/* LMALLOC is used for allocations of possibly larger than 64k */
/* LFREE is used to free buffers allocated with LMALLOC */
/* REALLOC is used to re-size a previously MALLOCed or LMALLOCed buffer */
/* FAR16 is used to create a far (32-bit) pointer in 16-bit compilers */
/* HUGE16 is used to create a huge (32-bit) pointer in 16-bit compilers */
/****************************************************************************/
#if defined(__COMPACT__) || defined(__LARGE__) || defined(__HUGE__)
#define HUGE16 huge
#define FAR16 far
#if defined(__TURBOC__)
#define REALLOC(x,y) farrealloc(x,y)
#define LMALLOC(x) farmalloc(x)
#define MALLOC(x) farmalloc(x)
#define LFREE(x) farfree(x)
#define FREE(x) farfree(x)
#elif defined(__WATCOMC__)
#define REALLOC realloc
#define LMALLOC(x) halloc(x,1)
/* far heap, but slow */
#define MALLOC malloc
/* far heap, but 64k max */
#define LFREE hfree
#define FREE free
#else
/* Other 16-bit Compiler */
#define REALLOC realloc
#define LMALLOC malloc
#define MALLOC malloc
#define LFREE free
#define FREE free
#endif
#else
/* 32-bit Compiler or Small Memory Model */
#define HUGE16
#define FAR16
#define REALLOC realloc
#define LMALLOC malloc
#define MALLOC malloc
#define LFREE free
#define FREE free
#endif
#endif
/* Don't add anything after this #endif statement */
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment