[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.3 and 1.44.4.1

version 1.36.2.3, 2006/01/01 23:12:36 version 1.44.4.1, 2007/11/06 23:11:13
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.3  
changed lines
  Added in v.1.44.4.1

CVSweb <webmaster@jp.NetBSD.org>