cvs commit: src/bin/sh cd.c

Stefan Farfeleder stefanf at FreeBSD.org
Sun Feb 24 16:50:56 UTC 2008


stefanf     2008-02-24 16:50:55 UTC

  FreeBSD src repository

  Modified files:
    bin/sh               cd.c 
  Log:
  Split updatepwd() into two smaller functions.  The first one, findpwd(),
  computes the new path and the second one, updatepwd(), updates the variables
  PWD, OLDPWD and the path used for the pwd builtin according to the new
  directory.  For a logical directory change, chdir() is now called between
  those two functions, no longer causing wrong values to be stored in PWD etc. if
  it fails.
  
  PR:     64990, 101316, 120571
  
  Revision  Changes    Path
  1.36      +45 -38    src/bin/sh/cd.c


More information about the cvs-src mailing list