nfs-ganesha 1.4
Defines | Functions

shell_vars.h File Reference

variables management for the shell. More...

#include <stdio.h>

Go to the source code of this file.

Defines

#define MAX_VAR_LEN   32

Functions

int is_authorized_varname (char *str)
char * get_var_value (char *varname)
int set_var_value (char *varname, char *var_value)
int free_var (char *varname)
void print_varlist (FILE *output, int is_dlen)

Detailed Description

variables management for the shell.

Author:
Author:
leibovic
Date:
Date:
2005/05/09 12:23:55
Version:
Revision:
1.2
Log:
shell_vars.h,v

Revision 1.2 2005/05/09 12:23:55 leibovic Version 2 of ganeshell.

Revision 1.1 2004/12/14 09:56:00 leibovic Variables management.

Definition in file shell_vars.h.


Define Documentation

#define MAX_VAR_LEN   32

Definition at line 24 of file shell_vars.h.


Function Documentation

int free_var ( char *  varname)

free the resources used by a variable.

Definition at line 283 of file shell_vars.c.

char* get_var_value ( char *  varname)

returns the value for a variable, NULL if the variable doesn't exist.

Definition at line 249 of file shell_vars.c.

int is_authorized_varname ( char *  str)

indicates whether a name is authorized for a variable. A variable name must be in [a-zA-Z0-9._:]*

Definition at line 219 of file shell_vars.c.

void print_varlist ( FILE *  output,
int  is_dlen 
)

print var list.

Parameters:
is_dlen,:indicates if it prints the length of the data they contain.

print var list.

Definition at line 115 of file shell_vars.c.

int set_var_value ( char *  varname,
char *  var_value 
)

set the value for a variable, and create it if necessary.

Definition at line 265 of file shell_vars.c.