getopt.c File Reference

Special re-entrant version of getopt. More...

#include "common.h"
#include <stdio.h>
#include <strings.h>
#include "machine.h"
#include "bu.h"

Include dependency graph for getopt.c:

Go to the source code of this file.

Defines

#define BADCH   (int)'?'
#define EMSG   ""
#define tell(s)

Functions

int bu_getopt (int nargc, char *const *nargv, const char *ostr)

Variables

int bu_opterr = 1
int bu_optind = 1
int bu_optopt = 0
char * bu_optarg = NULL


Detailed Description

Special re-entrant version of getopt.

Everything is prefixed with bu_, to distinguish it from the various getopt() routines found in libc.

Important note - If bu_getopt() it going to be used more than once, it is necessary to reinitialize bu_optind=1 before beginning on the next argument list.

Definition in file getopt.c.


Generated on Mon Sep 18 01:25:03 2006 for BRL-CAD by  doxygen 1.4.6