From: John L. <mov...@us...> - 2003-09-26 13:23:35
|
Update of /cvsroot/oprofile/oprofile/libutil In directory sc8-pr-cvs1:/tmp/cvs-serv10731/libutil Modified Files: Makefile.am op_file.c op_string.h Log Message: libutil tests - note the rel_to_abs_path failure, phe what's the issue ? Index: Makefile.am =================================================================== RCS file: /cvsroot/oprofile/oprofile/libutil/Makefile.am,v retrieving revision 1.8 retrieving revision 1.9 diff -u -p -d -r1.8 -r1.9 --- Makefile.am 9 Jun 2003 01:31:06 -0000 1.8 +++ Makefile.am 26 Sep 2003 13:23:32 -0000 1.9 @@ -1,3 +1,5 @@ +SUBDIRS = . tests + AM_CFLAGS = @OP_CFLAGS@ noinst_LIBRARIES = libutil.a Index: op_file.c =================================================================== RCS file: /cvsroot/oprofile/oprofile/libutil/op_file.c,v retrieving revision 1.15 retrieving revision 1.16 diff -u -p -d -r1.15 -r1.16 --- op_file.c 22 Sep 2003 14:10:17 -0000 1.15 +++ op_file.c 26 Sep 2003 13:23:32 -0000 1.16 @@ -208,7 +208,7 @@ char * op_relative_to_absolute_path(char char dir[PATH_MAX + 1]; char * temp_path = NULL; - if (path && path[0] != '/') { + if (path[0] != '/') { if (base_dir == NULL) { if (getcwd(dir, PATH_MAX) != NULL) { base_dir = dir; Index: op_string.h =================================================================== RCS file: /cvsroot/oprofile/oprofile/libutil/op_string.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -p -d -r1.1 -r1.2 --- op_string.h 15 Mar 2003 16:31:23 -0000 1.1 +++ op_string.h 26 Sep 2003 13:23:32 -0000 1.2 @@ -12,6 +12,8 @@ #ifndef OP_STRING_H #define OP_STRING_H +#include <string.h> + #ifdef __cplusplus extern "C" { #endif @@ -36,7 +38,7 @@ int strisprefix(char const * str, char c /** * @param c: input string * - * return a pointer to the first location in c whiwh is not a blank space + * return a pointer to the first location in c which is not a blank space * where blank space are in " \t\n" */ char const * skip_ws(char const * c); @@ -44,7 +46,7 @@ char const * skip_ws(char const * c); /** * @param c: input string * - * return a pointer to the first location in c whiwh is a blank space + * return a pointer to the first location in c which is a blank space * where blank space are in " \t\n" */ char const * skip_nonws(char const * c); @@ -52,7 +54,7 @@ char const * skip_nonws(char const * c); /** * @param c: input string * - * return non zero is c string contains only blank space + * return non zero if c string contains only blank space * where blank space are in " \t\n" */ int empty_line(char const * c); @@ -60,7 +62,7 @@ int empty_line(char const * c); /** * @param c: input string * - * return non zero is c string is a comment. Comment are line with optionnal + * return non zero is c string is a comment. Comment are lines with optional * blank space at left then a '#' character. Blank space are in " \t\n" */ int comment_line(char const * c); |