Functions

ut_files.cpp File Reference

#include "ut_files.h"
#include "ut_debugmsg.h"
#include "ut_types.h"
#include "ut_string.h"
#include "ut_misc.h"
#include "ut_vector.h"
#include "ut_string_class.h"

Functions

bool progExists (const char *progName)

Function Documentation

bool progExists ( const char *  progName  ) 

If progName is a fully qualified path (i.e. it begins with '/'), this function looks for the program with this path, returning true if it exists. Otherwise, progExists searchs the system PATH for the program progName, and returns true if it exists (i.e. is a regular file or symlink).

Ex: if(progExists("vi") { do_stuff(); }

Referenced by abi_plugin_register(), and XAP_UnixAppImpl::openURL().