From f5ee5be3d0b257d863eed42e42e8dfd601fc3a74 Mon Sep 17 00:00:00 2001 From: cristy Date: Fri, 6 Nov 2009 02:22:56 +0000 Subject: [PATCH] --- Makefile.am | 2 +- Makefile.in | 2 +- magick/utility.c | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index 529361254..201e3bddd 100644 --- a/Makefile.am +++ b/Makefile.am @@ -25,7 +25,7 @@ AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) ACLOCAL_AMFLAGS = -I m4 -MODULECOMMONFLAGS = -no-undefined -export-symbols-regex ".*" -module -avoid-version +MODULECOMMONFLAGS = -no-undefined -export-symbols-regex ".*" -shared -module -avoid-version # Options to pass when running configure in the distcheck target. # diff --git a/Makefile.in b/Makefile.in index d61088adf..420828691 100644 --- a/Makefile.in +++ b/Makefile.in @@ -2543,7 +2543,7 @@ AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) \ -I$(srcdir)/ltdl -I$(srcdir)/ltdl/libltdl \ -I$(top_srcdir)/Magick++/lib ACLOCAL_AMFLAGS = -I m4 -MODULECOMMONFLAGS = -no-undefined -export-symbols-regex ".*" -module -avoid-version +MODULECOMMONFLAGS = -no-undefined -export-symbols-regex ".*" -shared -module -avoid-version # Options to pass when running configure in the distcheck target. # diff --git a/magick/utility.c b/magick/utility.c index 196f94f65..3e242bfa4 100644 --- a/magick/utility.c +++ b/magick/utility.c @@ -702,7 +702,6 @@ MagickExport MagickBooleanType ExpandFilenames(int *number_arguments, Expand any wildcard filenames. */ *home_directory='\0'; - cwd=getcwd(home_directory,MaxTextExtent); count=0; for (i=0; i < (long) *number_arguments; i++) { @@ -758,6 +757,8 @@ MagickExport MagickBooleanType ExpandFilenames(int *number_arguments, GetPathComponent(option,HeadPath,path); GetPathComponent(option,SubimagePath,subimage); ExpandFilename(path); + if (*home_directory == '\0') + cwd=getcwd(home_directory,MaxTextExtent-1); filelist=ListFiles(*path == '\0' ? home_directory : path,filename, &number_files); } -- 2.50.1