diff -Naur gnome-vfs-2.0.4.1.old/Makefile.in gnome-vfs-2.0.4.1.new/Makefile.in --- gnome-vfs-2.0.4.1.old/Makefile.in Thu Nov 14 02:10:57 2002 +++ gnome-vfs-2.0.4.1.new/Makefile.in Sun Jan 19 18:23:13 2003 @@ -170,7 +170,7 @@ SUBDIRS_GNOME = monikers doc schemas -SUBDIRS = libgnomevfs modules schemas devel-docs doc test monikers po +SUBDIRS = libgnomevfs modules schemas devel-docs doc monikers po EXTRA_DIST = HACKING TODO autogen.sh gnome-vfs.spec gnome-vfs-2.0.pc.in gnome-vfs-module-2.0.pc.in intltool-extract.in intltool-merge.in intltool-update.in diff -Naur gnome-vfs-2.0.4.1.old/config.h.in gnome-vfs-2.0.4.1.new/config.h.in --- gnome-vfs-2.0.4.1.old/config.h.in Thu Nov 14 02:09:30 2002 +++ gnome-vfs-2.0.4.1.new/config.h.in Sun Jan 19 18:23:13 2003 @@ -59,6 +59,15 @@ /* Define to use SVR4 statvfs to get filesystem type. */ #undef FSTYPE_STATVFS +/* Define if you have the `strtok_r' function. */ +#undef HAVE_STRTOK_R + +/* Define if you have the `readdir_r' function. */ +#undef HAVE_READDIR_R + +/* Define if you have the `strptime' function. */ +#undef HAVE_STRPTIME + /* Define to use SVR3.2 statfs to get filesystem type. */ #undef FSTYPE_USG_STATFS diff -Naur gnome-vfs-2.0.4.1.old/configure gnome-vfs-2.0.4.1.new/configure --- gnome-vfs-2.0.4.1.old/configure Thu Nov 14 02:10:52 2002 +++ gnome-vfs-2.0.4.1.new/configure Sun Jan 19 18:23:13 2003 @@ -8592,7 +8592,7 @@ fi -for ac_func in getdtablesize open64 lseek64 statvfs +for ac_func in getdtablesize open64 lseek64 statvfs strtok_r readdir_r strptime do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo "configure:8599: checking for $ac_func" >&5 diff -Naur gnome-vfs-2.0.4.1.old/libgnomevfs/Makefile.in gnome-vfs-2.0.4.1.new/libgnomevfs/Makefile.in --- gnome-vfs-2.0.4.1.old/libgnomevfs/Makefile.in Thu Nov 14 02:10:58 2002 +++ gnome-vfs-2.0.4.1.new/libgnomevfs/Makefile.in Sun Jan 19 18:23:13 2003 @@ -188,7 +188,7 @@ libgnomevfsinclude_HEADERS = gnome-vfs-application-registry.h gnome-vfs-async-ops.h gnome-vfs-cancellation.h gnome-vfs-context.h gnome-vfs-directory.h gnome-vfs-file-info.h gnome-vfs-file-size.h gnome-vfs-find-directory.h gnome-vfs-handle.h gnome-vfs-init.h gnome-vfs-job-limit.h gnome-vfs-mime-utils.h gnome-vfs-mime-handlers.h gnome-vfs-mime-monitor.h gnome-vfs-module-callback.h gnome-vfs-monitor.h gnome-vfs-ops.h gnome-vfs-result.h gnome-vfs-standard-callbacks.h gnome-vfs-types.h gnome-vfs-uri.h gnome-vfs-utils.h gnome-vfs-xfer.h gnome-vfs.h $(NULL) -libgnomevfs_2_la_SOURCES = gnome-vfs-application-registry.c gnome-vfs-async-job-map.c gnome-vfs-async-ops.c gnome-vfs-backend.h gnome-vfs-cancellable-ops.c gnome-vfs-cancellable-ops.h gnome-vfs-cancellation.c gnome-vfs-configuration.c gnome-vfs-configuration.h gnome-vfs-context.c gnome-vfs-directory.c gnome-vfs-file-info.c gnome-vfs-find-directory.c gnome-vfs-handle.c gnome-vfs-i18n.c gnome-vfs-i18n.h gnome-vfs-inet-connection.c gnome-vfs-init.c gnome-vfs-iobuf.c gnome-vfs-job-queue.c gnome-vfs-job-slave.c gnome-vfs-job.c gnome-vfs-method.c gnome-vfs-mime-handlers.c gnome-vfs-mime-info.c gnome-vfs-mime-magic.c gnome-vfs-mime-monitor.c gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer.c gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-mime.c gnome-vfs-module-callback-module-api.c gnome-vfs-module-callback-private.c gnome-vfs-module-callback-private.h gnome-vfs-module-callback.c gnome-vfs-module-shared.c gnome-vfs-module.c gnome-vfs-monitor.c gnome-vfs-monitor-private.h gnome-vfs-ops.c gnome-vfs-parse-ls.c gnome-vfs-private-utils.c gnome-vfs-private-utils.h gnome-vfs-private.c gnome-vfs-private.h gnome-vfs-process.c gnome-vfs-process.h gnome-vfs-result.c gnome-vfs-socket-buffer.c gnome-vfs-socket.c gnome-vfs-ssl.c gnome-vfs-ssl-private.h gnome-vfs-thread-pool.c gnome-vfs-transform.c gnome-vfs-uri.c gnome-vfs-utils.c gnome-vfs-xfer.c gnome-vfs-async-job-map.h gnome-vfs-backend.h gnome-vfs-i18n.h gnome-vfs-job-queue.h gnome-vfs-job-slave.h gnome-vfs-job.h gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-module-callback-private.h gnome-vfs-process.h gnome-vfs-thread-pool.h $(NULL) +libgnomevfs_2_la_SOURCES = gnome-vfs-application-registry.c gnome-vfs-async-job-map.c gnome-vfs-async-ops.c gnome-vfs-backend.h gnome-vfs-cancellable-ops.c gnome-vfs-cancellable-ops.h gnome-vfs-cancellation.c gnome-vfs-configuration.c gnome-vfs-configuration.h gnome-vfs-context.c gnome-vfs-directory.c gnome-vfs-file-info.c gnome-vfs-find-directory.c gnome-vfs-handle.c gnome-vfs-i18n.c gnome-vfs-i18n.h gnome-vfs-inet-connection.c gnome-vfs-init.c gnome-vfs-iobuf.c gnome-vfs-job-queue.c gnome-vfs-job-slave.c gnome-vfs-job.c gnome-vfs-method.c gnome-vfs-mime-handlers.c gnome-vfs-mime-info.c gnome-vfs-mime-magic.c gnome-vfs-mime-monitor.c gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer.c gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-mime.c gnome-vfs-module-callback-module-api.c gnome-vfs-module-callback-private.c gnome-vfs-module-callback-private.h gnome-vfs-module-callback.c gnome-vfs-module-shared.c gnome-vfs-module.c gnome-vfs-monitor.c gnome-vfs-monitor-private.h gnome-vfs-ops.c gnome-vfs-parse-ls.c gnome-vfs-private-utils.c gnome-vfs-private-utils.h gnome-vfs-private.c gnome-vfs-private.h gnome-vfs-process.c gnome-vfs-process.h gnome-vfs-result.c gnome-vfs-socket-buffer.c gnome-vfs-socket.c gnome-vfs-ssl.c gnome-vfs-ssl-private.h gnome-vfs-thread-pool.c gnome-vfs-transform.c gnome-vfs-uri.c gnome-vfs-utils.c gnome-vfs-xfer.c gnome-vfs-async-job-map.h gnome-vfs-backend.h gnome-vfs-i18n.h gnome-vfs-job-queue.h gnome-vfs-job-slave.h gnome-vfs-job.h gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-module-callback-private.h gnome-vfs-process.h gnome-vfs-thread-pool.h strptime.c $(NULL) # Platform specific includes diff -Naur gnome-vfs-2.0.4.1.old/libgnomevfs/gnome-vfs-configuration.c gnome-vfs-2.0.4.1.new/libgnomevfs/gnome-vfs-configuration.c --- gnome-vfs-2.0.4.1.old/libgnomevfs/gnome-vfs-configuration.c Thu Sep 19 19:11:25 2002 +++ gnome-vfs-2.0.4.1.new/libgnomevfs/gnome-vfs-configuration.c Sun Jan 19 18:23:13 2003 @@ -24,6 +24,7 @@ #include #include "gnome-vfs-configuration.h" +#include #include #include #include diff -Naur gnome-vfs-2.0.4.1.old/libgnomevfs/gnome-vfs-mime.c gnome-vfs-2.0.4.1.new/libgnomevfs/gnome-vfs-mime.c --- gnome-vfs-2.0.4.1.old/libgnomevfs/gnome-vfs-mime.c Wed Jun 26 11:33:32 2002 +++ gnome-vfs-2.0.4.1.new/libgnomevfs/gnome-vfs-mime.c Sun Jan 19 18:23:13 2003 @@ -81,6 +81,31 @@ #endif /* G_LOCK_DEFINE_STATIC */ +#ifndef HAVE_STRTOK_R +static char * +strtok_r (char *s, const char *delim, char **save_ptr) +{ + char *token; + + if (s == NULL) + s = *save_ptr; + + s += strspn (s, delim); + if (*s == '\0') + return NULL; + + token = s; + s = strpbrk (token, delim); + if (s == NULL) { + *save_ptr = strchr (token, '\0'); + } else { + *s = '\0'; + *save_ptr = s + 1; + } + return token; +} +#endif + static char * get_priority (char *def, int *priority) { diff -Naur gnome-vfs-2.0.4.1.old/libgnomevfs/strptime.c gnome-vfs-2.0.4.1.new/libgnomevfs/strptime.c --- gnome-vfs-2.0.4.1.old/libgnomevfs/strptime.c Thu Jan 1 09:00:00 1970 +++ gnome-vfs-2.0.4.1.new/libgnomevfs/strptime.c Sun Jan 19 18:23:13 2003 @@ -0,0 +1,368 @@ +/* + * Copyright (c) 1994 Powerdog Industries. All rights reserved. + * + * Redistribution and use in source and binary forms, without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgement: + * This product includes software developed by Powerdog Industries. + * 4. The name of Powerdog Industries may not be used to endorse or + * promote products derived from this software without specific prior + * written permission. + * + * THIS SOFTWARE IS PROVIDED BY POWERDOG INDUSTRIES ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE POWERDOG INDUSTRIES BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include + +#ifndef HAVE_STRPTIME + +#include +#include +#include +#include + +#define asizeof(a) (sizeof (a) / sizeof ((a)[0])) + +struct dtconv { + char *abbrev_month_names[12]; + char *month_names[12]; + char *abbrev_weekday_names[7]; + char *weekday_names[7]; + char *time_format; + char *sdate_format; + char *dtime_format; + char *am_string; + char *pm_string; + char *ldate_format; +}; + +static struct dtconv En_US = { + { "Jan", "Feb", "Mar", "Apr", "May", "Jun", + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }, + { "January", "February", "March", "April", + "May", "June", "July", "August", + "September", "October", "November", "December" }, + { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" }, + { "Sunday", "Monday", "Tuesday", "Wednesday", + "Thursday", "Friday", "Saturday" }, + "%H:%M:%S", + "%m/%d/%y", + "%a %b %e %T %Z %Y", + "AM", + "PM", + "%A, %B, %e, %Y" +}; + +#if defined(__APPLE__) +__private_extern__ +#endif +char * +strptime(char *buf, char *fmt, struct tm *tm) +{ + char c, *ptr; + int i, len = 0; + + ptr = fmt; + while (*ptr != 0) + { + if (*buf == 0) + break; + + c = *ptr++; + + if (c != '%') + { + if (isspace(c)) + while (*buf != 0 && isspace(*buf)) + buf++; + else if (c != *buf++) + return 0; + continue; + } + + c = *ptr++; + switch (c) + { + case 0: + case '%': + if (*buf++ != '%') + return 0; + break; + + case 'C': + buf = strptime(buf, En_US.ldate_format, tm); + if (buf == 0) + return 0; + break; + + case 'c': + buf = strptime(buf, "%x %X", tm); + if (buf == 0) + return 0; + break; + + case 'D': + buf = strptime(buf, "%m/%d/%y", tm); + if (buf == 0) + return 0; + break; + + case 'R': + buf = strptime(buf, "%H:%M", tm); + if (buf == 0) + return 0; + break; + + case 'r': + buf = strptime(buf, "%I:%M:%S %p", tm); + if (buf == 0) + return 0; + break; + + case 'T': + buf = strptime(buf, "%H:%M:%S", tm); + if (buf == 0) + return 0; + break; + + case 'X': + buf = strptime(buf, En_US.time_format, tm); + if (buf == 0) + return 0; + break; + + case 'x': + buf = strptime(buf, En_US.sdate_format, tm); + if (buf == 0) + return 0; + break; + + case 'j': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 365) + return 0; + + tm->tm_yday = i; + break; + + case 'M': + case 'S': + if (*buf == 0 || isspace(*buf)) + break; + + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 59) + return 0; + + if (c == 'M') + tm->tm_min = i; + else + tm->tm_sec = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'H': + case 'I': + case 'k': + case 'l': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (c == 'H' || c == 'k') { + if (i > 23) + return 0; + } else if (i > 11) + return 0; + + tm->tm_hour = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'p': + len = strlen(En_US.am_string); + if (strncasecmp(buf, En_US.am_string, len) == 0) + { + if (tm->tm_hour > 12) + return 0; + if (tm->tm_hour == 12) + tm->tm_hour = 0; + buf += len; + break; + } + + len = strlen(En_US.pm_string); + if (strncasecmp(buf, En_US.pm_string, len) == 0) + { + if (tm->tm_hour > 12) + return 0; + if (tm->tm_hour != 12) + tm->tm_hour += 12; + buf += len; + break; + } + + return 0; + + case 'A': + case 'a': + for (i = 0; i < asizeof(En_US.weekday_names); i++) + { + len = strlen(En_US.weekday_names[i]); + if (strncasecmp(buf, + En_US.weekday_names[i], + len) == 0) + break; + + len = strlen(En_US.abbrev_weekday_names[i]); + if (strncasecmp(buf, + En_US.abbrev_weekday_names[i], + len) == 0) + break; + } + if (i == asizeof(En_US.weekday_names)) + return 0; + + tm->tm_wday = i; + buf += len; + break; + + case 'd': + case 'e': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 31) + return 0; + + tm->tm_mday = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'B': + case 'b': + case 'h': + for (i = 0; i < asizeof(En_US.month_names); i++) + { + len = strlen(En_US.month_names[i]); + if (strncasecmp(buf, + En_US.month_names[i], + len) == 0) + break; + + len = strlen(En_US.abbrev_month_names[i]); + if (strncasecmp(buf, + En_US.abbrev_month_names[i], + len) == 0) + break; + } + if (i == asizeof(En_US.month_names)) + return 0; + + tm->tm_mon = i; + buf += len; + break; + + case 'm': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i < 1 || i > 12) + return 0; + + tm->tm_mon = i - 1; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'Y': + case 'y': + if (*buf == 0 || isspace(*buf)) + break; + + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (c == 'y' && i < 69) /* Unix Epoch pivot year */ + i += 100; + if (c == 'Y') + i -= 1900; + if (i < 0) + return 0; + + tm->tm_year = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + } + } + + return buf; +} + +#endif /* !HAVE_STRPTIME */ + diff -Naur gnome-vfs-2.0.4.1.old/ltmain.sh gnome-vfs-2.0.4.1.new/ltmain.sh --- gnome-vfs-2.0.4.1.old/ltmain.sh Thu Nov 14 02:09:29 2002 +++ gnome-vfs-2.0.4.1.new/ltmain.sh Sun Jan 19 18:23:25 2003 @@ -4045,10 +4045,10 @@ # Directory that this library needs to be installed in: libdir='$install_libdir'" - if test "$installed" = no && test $need_relink = yes; then - $echo >> $output "\ -relink_command=\"$relink_command\"" - fi +# if test "$installed" = no && test $need_relink = yes; then +# $echo >> $output "\ +#relink_command=\"$relink_command\"" +# fi done fi diff -Naur gnome-vfs-2.0.4.1.old/modules/file-method.c gnome-vfs-2.0.4.1.new/modules/file-method.c --- gnome-vfs-2.0.4.1.old/modules/file-method.c Thu Aug 15 21:04:12 2002 +++ gnome-vfs-2.0.4.1.new/modules/file-method.c Sun Jan 19 18:23:13 2003 @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #include @@ -46,13 +47,46 @@ #include #include #include -#include #include #include #include #ifdef HAVE_FAM #include #include +#endif + +#ifndef HAVE_READDIR_R +static int +readdir_r (DIR *dirp, struct dirent *entry, struct dirent **result) +{ + static int readdir_mutex_inited = 0; + static pthread_mutex_t readdir_mutex; + struct dirent *tmp; + int old_errno; + + if (!readdir_mutex_inited) { + readdir_mutex_inited = 1; + pthread_mutex_init (&readdir_mutex, NULL); + } + + old_errno = errno; + errno = 0; + + pthread_mutex_lock (&readdir_mutex); + if ((tmp = readdir (dirp)) != NULL) + memcpy (entry, tmp, sizeof (*entry)); + pthread_mutex_unlock (&readdir_mutex); + + if (errno && !tmp) + return errno; + + if (!errno) + errno = old_errno; + + *result = (tmp) ? entry : NULL; + + return 0; +} #endif #ifdef HAVE_FAM diff -Naur gnome-vfs-2.0.4.1.old/modules/fstype.c gnome-vfs-2.0.4.1.new/modules/fstype.c --- gnome-vfs-2.0.4.1.old/modules/fstype.c Thu Aug 8 05:52:44 2002 +++ gnome-vfs-2.0.4.1.new/modules/fstype.c Sun Jan 19 18:23:14 2003 @@ -357,7 +357,7 @@ char *p; if (S_ISLNK (statp->st_mode)) - p = dirname (relpath); + p = g_path_get_dirname (relpath); else p = relpath; diff -Naur gnome-vfs-2.0.4.1.old/modules/vfolder/Makefile.in gnome-vfs-2.0.4.1.new/modules/vfolder/Makefile.in --- gnome-vfs-2.0.4.1.old/modules/vfolder/Makefile.in Thu Nov 14 02:11:01 2002 +++ gnome-vfs-2.0.4.1.new/modules/vfolder/Makefile.in Sun Jan 19 18:23:14 2003 @@ -178,7 +178,7 @@ ### Module setup -module_flags = -export_dynamic -avoid-version +module_flags = -export_dynamic -avoid-version -module modulesdir = $(libdir)/gnome-vfs-2.0/modules modules_LTLIBRARIES = libvfolder-desktop.la