[BACK]Return to getcwd.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / lib / libc / gen

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/lib/libc/gen/getcwd.c between version 1.36.2.1 and 1.45

version 1.36.2.1, 2005/08/14 22:08:44 version 1.45, 2007/10/26 19:48:14
Line 96  realpath(const char *path, char *resolve
Line 96  realpath(const char *path, char *resolve
   
         /* If relative path, start from current working directory. */          /* If relative path, start from current working directory. */
         if (*path != '/') {          if (*path != '/') {
                 if (getcwd(resolved, MAXPATHLEN) == NULL) {                  /* check for resolved pointer to appease coverity */
                   if (resolved && getcwd(resolved, MAXPATHLEN) == NULL) {
                         p[0] = '.';                          p[0] = '.';
                         p[1] = 0;                          p[1] = 0;
                         return (NULL);                          return (NULL);
Line 199  loop:
Line 200  loop:
         goto loop;          goto loop;
 }  }
   
   
   #if defined(_FORTIFY_SOURCE) && !defined(__lint__)
   #undef getcwd
   #define getcwd _getcwd
   #endif
   
 char *  char *
 getcwd(char *pt, size_t size)  getcwd(char *pt, size_t size)
 {  {

Legend:
Removed from v.1.36.2.1  
changed lines
  Added in v.1.45

CVSweb <webmaster@jp.NetBSD.org>