Coda Distributed File System
Macros | Functions | Variables
asrlauncher.c File Reference
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <sys/param.h>
#include <errno.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <signal.h>
#include <coda_config.h>
Include dependency graph for asrlauncher.c:

Macros

#define NCARGS   8192
 
#define ASR_RULES_FILENAME   ".asr"
 
#define ASR_TIMEOUT   60000
 
#define TRIGGER_TIMEOUT   ASR_TIMEOUT
 
#define CONFLICT_BASENAME   '>' /* Puneet's original 3 vars */
 
#define CONFLICT_PARENT   '<'
 
#define SYSTYPE_VAR   '@'
 
#define CONFLICT_PATH   '=' /* Additional variables */
 
#define CONFLICT_VOLUME   ':'
 
#define CONFLICT_TYPE   '!'
 
#define SERVER_SERVER   1
 
#define SERVER_SERVER_STR   "1"
 
#define SERVER_SERVER_CHAR   'S'
 
#define LOCAL_GLOBAL   2
 
#define LOCAL_GLOBAL_STR   "2"
 
#define LOCAL_GLOBAL_CHAR   'L'
 
#define MIXED_CONFLICT   3
 
#define MIXED_CONFLICT_STR   "3"
 
#define MIXED_CONFLICT_CHAR   'M'
 

Functions

int escapeString (char *str, int maxlen)
 
int nameNextRulesFile (char *path)
 
int checkRulesFile (char *pathname)
 
int replaceEnvVars (char *string, int maxlen)
 
int executeTriggers (long *cmds)
 
int findRule (long *cmds)
 
int executeCommands (long cmds)
 
int main (int argc, char *argv[])
 

Variables

int My_Pid
 
char Local_Policy_Path [MAXPATHLEN]
 
int Conflict_Type
 
char Conflict_Path [MAXPATHLEN]
 
char Conflict_Parent [MAXPATHLEN]
 
char * Conflict_Basename
 
char Conflict_Volume_Path [MAXPATHLEN]
 
FILE * Rules_File
 
char Rules_File_Path [MAXPATHLEN]
 
char Rules_File_Parent [MAXPATHLEN]
 

Macro Definition Documentation

◆ ASR_RULES_FILENAME

#define ASR_RULES_FILENAME   ".asr"

◆ ASR_TIMEOUT

#define ASR_TIMEOUT   60000

◆ CONFLICT_BASENAME

#define CONFLICT_BASENAME   '>' /* Puneet's original 3 vars */

◆ CONFLICT_PARENT

#define CONFLICT_PARENT   '<'

◆ CONFLICT_PATH

#define CONFLICT_PATH   '=' /* Additional variables */

◆ CONFLICT_TYPE

#define CONFLICT_TYPE   '!'

◆ CONFLICT_VOLUME

#define CONFLICT_VOLUME   ':'

◆ LOCAL_GLOBAL

#define LOCAL_GLOBAL   2

◆ LOCAL_GLOBAL_CHAR

#define LOCAL_GLOBAL_CHAR   'L'

◆ LOCAL_GLOBAL_STR

#define LOCAL_GLOBAL_STR   "2"

◆ MIXED_CONFLICT

#define MIXED_CONFLICT   3

◆ MIXED_CONFLICT_CHAR

#define MIXED_CONFLICT_CHAR   'M'

◆ MIXED_CONFLICT_STR

#define MIXED_CONFLICT_STR   "3"

◆ NCARGS

#define NCARGS   8192

◆ SERVER_SERVER

#define SERVER_SERVER   1

◆ SERVER_SERVER_CHAR

#define SERVER_SERVER_CHAR   'S'

◆ SERVER_SERVER_STR

#define SERVER_SERVER_STR   "1"

◆ SYSTYPE_VAR

#define SYSTYPE_VAR   '@'

◆ TRIGGER_TIMEOUT

#define TRIGGER_TIMEOUT   ASR_TIMEOUT

Function Documentation

◆ checkRulesFile()

int checkRulesFile ( char *  pathname)

◆ escapeString()

int escapeString ( char *  str,
int  maxlen 
)

◆ executeCommands()

int executeCommands ( long  cmds)

◆ executeTriggers()

int executeTriggers ( long *  cmds)

◆ findRule()

int findRule ( long *  cmds)

◆ main()

int main ( int  argc,
char *  argv[] 
)

◆ nameNextRulesFile()

int nameNextRulesFile ( char *  path)

◆ replaceEnvVars()

int replaceEnvVars ( char *  string,
int  maxlen 
)

Variable Documentation

◆ Conflict_Basename

char* Conflict_Basename

◆ Conflict_Parent

char Conflict_Parent[MAXPATHLEN]

◆ Conflict_Path

char Conflict_Path[MAXPATHLEN]

◆ Conflict_Type

int Conflict_Type

◆ Conflict_Volume_Path

char Conflict_Volume_Path[MAXPATHLEN]

◆ Local_Policy_Path

char Local_Policy_Path[MAXPATHLEN]

◆ My_Pid

int My_Pid

◆ Rules_File

FILE* Rules_File

◆ Rules_File_Parent

char Rules_File_Parent[MAXPATHLEN]

◆ Rules_File_Path

char Rules_File_Path[MAXPATHLEN]