File: lstring.h

package info (click to toggle)
afdko 3.6.2%2Bdfsg1-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 19,172 kB
  • sloc: ansic: 218,471; python: 17,440; cpp: 3,500; makefile: 3,172; sh: 464; yacc: 421; cs: 47
file content (46 lines) | stat: -rw-r--r-- 1,249 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/* Copyright 2014 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved.
This software is licensed as OpenSource, under the Apache License, Version 2.0.
This license is available at: http://opensource.org/licenses/Apache-2.0. */
/***********************************************************************/

/* Veneer layer for string.h */
#ifndef LSTRING_H
#define LSTRING_H

#if WITHIN_PS

/* PostScript environment */
#include PACKAGE_SPECS
#include ENVIRONMENT
#include PROTOS
#include EXCEPT
#include PUBLICTYPES
#include PSLIB
#include UTIL

#define strncpy os_strncpy
#define strcpy os_strcpy
#define strncmp os_strncmp
#define strcmp os_strcmp
#define strlen os_strlen
#define strchr os_index
double strtod(const char *str, char **ptr);
long strtol(const char *str, char **ptr, int base);
#define memcpy(d, s, n) os_bcopy(s, d, n)
#define memmove(d, s, n) os_bcopy(s, d, n)
#define memset(d, v, n) os_bvalue(d, n, v)

#else /* WITHIN_PS */

/* ANSI C environment */
#include <string.h>

#if SUNOS
/* SunOS libc doesn't define memmove() but bcopy() can be substituted */
char *bcopy(const void *src, void *dst, int len);
#define memmove(d, s, l) bcopy(s, d, l)
#endif /* SUNOS */

#endif /* WITHIN_PS */

#endif /* LSTRING_H */