js/src/editline/editline.h

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
     2  * This Source Code Form is subject to the terms of the Mozilla Public
     3  * License, v. 2.0. If a copy of the MPL was not distributed with this
     4  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     6 #ifndef editline_editline_h
     7 #define editline_editline_h
     9 /*
    10  * Copyright 1992,1993 Simmule Turner and Rich Salz.  All rights reserved.
    11  *
    12  * This software is not subject to any license of the American Telephone
    13  * and Telegraph Company or of the Regents of the University of California.
    14  *
    15  * Permission is granted to anyone to use this software for any purpose on
    16  * any computer system, and to alter it and redistribute it freely, subject
    17  * to the following restrictions:
    18  * 1. The authors are not responsible for the consequences of use of this
    19  *    software, no matter how awful, even if they arise from flaws in it.
    20  * 2. The origin of this software must not be misrepresented, either by
    21  *    explicit claim or by omission.  Since few users ever read sources,
    22  *    credits must appear in the documentation.
    23  * 3. Altered versions must be plainly marked as such, and must not be
    24  *    misrepresented as being the original software.  Since few users
    25  *    ever read sources, credits must appear in the documentation.
    26  * 4. This notice may not be removed or altered.
    27  */
    29 /*
    30 **  Internal header file for editline library.
    31 */
    32 #include <stdio.h>
    33 #if	defined(HAVE_STDLIB)
    34 #include <stdlib.h>
    35 #include <string.h>
    36 #endif	/* defined(HAVE_STDLIB) */
    37 #if	defined(SYS_UNIX)
    38 #include "unix.h"
    39 #endif	/* defined(SYS_UNIX) */
    40 #if	defined(SYS_OS9)
    41 #include "os9.h"
    42 #endif	/* defined(SYS_OS9) */
    44 #if	!defined(SIZE_T)
    45 #define SIZE_T	unsigned int
    46 #endif	/* !defined(SIZE_T) */
    48 typedef unsigned char	CHAR;
    50 #if	defined(HIDE)
    51 #define STATIC	static
    52 #else
    53 #define STATIC	/* NULL */
    54 #endif	/* !defined(HIDE) */
    56 #define CONST	const
    58 #define MEM_INC		64
    59 #define SCREEN_INC	256
    61 #define DISPOSE(p)	free((char *)(p))
    62 #define NEW(T, c)	\
    63 	((T *)malloc((unsigned int)(sizeof (T) * (c))))
    64 #define RENEW(p, T, c)	\
    65 	(p = (T *)realloc((char *)(p), (unsigned int)(sizeof (T) * (c))))
    66 #define COPYFROMTO(new, p, len)	\
    67 	(void)memcpy((char *)(new), (char *)(p), (int)(len))
    70 /*
    71 **  Variables and routines internal to this package.
    72 */
    73 extern unsigned rl_eof;
    74 extern unsigned rl_erase;
    75 extern unsigned rl_intr;
    76 extern unsigned rl_kill;
    77 extern unsigned rl_quit;
    78 extern char	*rl_complete();
    79 extern int	rl_list_possib();
    80 extern void	rl_ttyset(int);
    81 extern void	rl_add_slash();
    83 #if	!defined(HAVE_STDLIB)
    84 extern char	*getenv();
    85 extern char	*malloc();
    86 extern char	*realloc();
    87 extern char	*memcpy();
    88 extern char	*strcat();
    89 extern char	*strchr();
    90 extern char	*strrchr();
    91 extern char	*strcpy();
    92 extern char	*strdup();
    93 extern int	strcmp();
    94 extern int	strlen();
    95 extern int	strncmp();
    96 #endif	/* !defined(HAVE_STDLIB) */
    98 #endif /* editline_editline_h */

mercurial