Print this page
remove support for non-ANSI compilation


   2  * CDDL HEADER START
   3  *
   4  * The contents of this file are subject to the terms of the
   5  * Common Development and Distribution License, Version 1.0 only
   6  * (the "License").  You may not use this file except in compliance
   7  * with the License.
   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */



  22 /*      Copyright (c) 1988 AT&T     */
  23 /*        All Rights Reserved   */
  24 
  25 
  26 #ifndef _PFMT_H
  27 #define _PFMT_H
  28 
  29 #pragma ident   "%Z%%M% %I%     %E% SMI"
  30 
  31 #include <stdio.h>
  32 #ifndef va_args
  33 #include <stdarg.h>
  34 #endif
  35 
  36 #ifdef  __cplusplus
  37 extern "C" {
  38 #endif
  39 
  40 #define MM_STD          0
  41 #define MM_NOSTD        0x100
  42 #define MM_GET          0
  43 #define MM_NOGET        0x200
  44 
  45 #define MM_ACTION       0x400
  46 
  47 #define MM_NOCONSOLE    0
  48 #define MM_CONSOLE      0x800
  49 
  50 /* Classification */
  51 #define MM_NULLMC       0
  52 #define MM_HARD         0x1000
  53 #define MM_SOFT         0x2000
  54 #define MM_FIRM         0x4000
  55 #define MM_APPL         0x8000
  56 #define MM_UTIL         0x10000
  57 #define MM_OPSYS        0x20000
  58 
  59 /* Most commonly used combinations */
  60 #define MM_SVCMD        MM_UTIL|MM_SOFT
  61 
  62 #define MM_ERROR        0
  63 #define MM_HALT         1
  64 #define MM_WARNING      2
  65 #define MM_INFO         3
  66 
  67 #ifdef __STDC__
  68 int pfmt(FILE *, long, const char *, ...);
  69 int lfmt(FILE *, long, const char *, ...);
  70 int vpfmt(FILE *, long, const char *, va_list);
  71 int vlfmt(FILE *, long, const char *, va_list);
  72 const char *setcat(const char *);
  73 int setlabel(const char *);
  74 int addsev(int, const char *);
  75 #else
  76 int pfmt();
  77 int lfmt();
  78 int vpfmt();
  79 int vlfmt();
  80 char *setcat();
  81 int setlabel();
  82 int addsev();
  83 #endif
  84 
  85 #define DB_NAME_LEN             15
  86 #define MAXLABEL                25
  87 
  88 #ifdef  __cplusplus
  89 }
  90 #endif
  91 
  92 #endif  /* _PFMT_H */


   2  * CDDL HEADER START
   3  *
   4  * The contents of this file are subject to the terms of the
   5  * Common Development and Distribution License, Version 1.0 only
   6  * (the "License").  You may not use this file except in compliance
   7  * with the License.
   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */
  22 /*
  23  * Copyright 2014 Garrett D'Amore <garrett@damore.org>
  24  */
  25 /*      Copyright (c) 1988 AT&T     */
  26 /*        All Rights Reserved   */
  27 

  28 #ifndef _PFMT_H
  29 #define _PFMT_H
  30 


  31 #include <stdio.h>
  32 #ifndef va_args
  33 #include <stdarg.h>
  34 #endif
  35 
  36 #ifdef  __cplusplus
  37 extern "C" {
  38 #endif
  39 
  40 #define MM_STD          0
  41 #define MM_NOSTD        0x100
  42 #define MM_GET          0
  43 #define MM_NOGET        0x200
  44 
  45 #define MM_ACTION       0x400
  46 
  47 #define MM_NOCONSOLE    0
  48 #define MM_CONSOLE      0x800
  49 
  50 /* Classification */
  51 #define MM_NULLMC       0
  52 #define MM_HARD         0x1000
  53 #define MM_SOFT         0x2000
  54 #define MM_FIRM         0x4000
  55 #define MM_APPL         0x8000
  56 #define MM_UTIL         0x10000
  57 #define MM_OPSYS        0x20000
  58 
  59 /* Most commonly used combinations */
  60 #define MM_SVCMD        MM_UTIL|MM_SOFT
  61 
  62 #define MM_ERROR        0
  63 #define MM_HALT         1
  64 #define MM_WARNING      2
  65 #define MM_INFO         3
  66 

  67 int pfmt(FILE *, long, const char *, ...);
  68 int lfmt(FILE *, long, const char *, ...);
  69 int vpfmt(FILE *, long, const char *, va_list);
  70 int vlfmt(FILE *, long, const char *, va_list);
  71 const char *setcat(const char *);
  72 int setlabel(const char *);
  73 int addsev(int, const char *);









  74 
  75 #define DB_NAME_LEN             15
  76 #define MAXLABEL                25
  77 
  78 #ifdef  __cplusplus
  79 }
  80 #endif
  81 
  82 #endif  /* _PFMT_H */