Mesa (master): bin/mklib: Clear CDPATH to avoid damaging expand_archive output

Keith Packard keithp at kemper.freedesktop.org
Mon Feb 22 17:57:03 UTC 2010


Module: Mesa
Branch: master
Commit: edd85bcd6bc92beaf266a602da76d2aefe836a8e
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=edd85bcd6bc92beaf266a602da76d2aefe836a8e

Author: Keith Packard <keithp at keithp.com>
Date:   Sun Feb 21 14:30:00 2010 -0800

bin/mklib: Clear CDPATH to avoid damaging expand_archive output

The bash 'cd' command tends to emit random stuff to stdout when the
CDPATH variable is set, so clear it to keep extra filenames from being
emitted from the expand_archive function, which would otherwise cause
mklib to fail.

Signed-off-by: Keith Packard <keithp at keithp.com>
Reviewed-by: Dan Nicholson <dbn.lists at gmail.com>
Signed-off-by: Brian Paul <brianp at vmware.com>

---

 bin/mklib |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/bin/mklib b/bin/mklib
index 06e8029..7f22725 100755
--- a/bin/mklib
+++ b/bin/mklib
@@ -25,6 +25,10 @@
 # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
 
+# Clear CDPATH as the 'cd' command will echo stuff
+# to stdout if it is set
+unset CDPATH
+
 # Given a list of files, look for .a archives and unpack them.
 # Return the original list of files minus the .a files plus the unpacked files.
 # first param:  name of a temp directory (to be deleted when finished)




More information about the mesa-commit mailing list