~ubuntu-branches/ubuntu/saucy/globus-gass-copy/saucy-proposed

« back to all changes in this revision

Viewing changes to debian/patches/globus-gass-copy-pathmax.patch

  • Committer: Package Import Robot
  • Author(s): Mattias Ellert
  • Date: 2011-12-28 20:48:04 UTC
  • mfrom: (1.2.5)
  • Revision ID: package-import@ubuntu.com-20111228204804-ir2pp35bx5425f6u
Tags: 8.2-1
* Update to Globus Toolkit 5.2.0
* Drop patches globus-gass-copy-doxygen.patch, globus-gass-copy-mingw.patch
  and globus-gass-copy-pathmax.patch (fixed upstream)
* Make doc package architecture independent

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
diff -ur globus_gass_copy-5.3.orig/globus_gass_copy_glob.c globus_gass_copy-5.3/globus_gass_copy_glob.c
2
 
--- globus_gass_copy-5.3.orig/globus_gass_copy_glob.c   2009-07-16 21:28:09.000000000 +0200
3
 
+++ globus_gass_copy-5.3/globus_gass_copy_glob.c        2010-01-23 10:12:08.902533517 +0100
4
 
@@ -20,6 +20,9 @@
5
 
 #include <fnmatch.h>
6
 
 #endif
7
 
 
8
 
+#ifndef MAXPATHLEN
9
 
+#define MAXPATHLEN 4096
10
 
+#endif
11
 
 
12
 
 /************************************************************
13
 
  * glob support
14
 
diff -ur globus_gass_copy-5.3.orig/globus_url_copy.c globus_gass_copy-5.3/globus_url_copy.c
15
 
--- globus_gass_copy-5.3.orig/globus_url_copy.c 2009-12-18 06:51:45.000000000 +0100
16
 
+++ globus_gass_copy-5.3/globus_url_copy.c      2010-01-23 10:20:00.162279634 +0100
17
 
@@ -42,6 +42,7 @@
18
 
 #include "globus_ftp_client_debug_plugin.h"
19
 
 #include "globus_ftp_client_restart_plugin.h"
20
 
 #include "globus_error_gssapi.h"
21
 
+#include "globus_gsi_system_config.h"
22
 
 
23
 
 /*
24
 
  *  use globus_io for netlogger stuff
25
 
@@ -2894,7 +2895,8 @@
26
 
 {
27
 
     char *                              tmp_ptr;
28
 
     char *                              tmp_path;
29
 
-    char                                start_dir[PATH_MAX];
30
 
+    char *                              start_dir = NULL;
31
 
+    globus_result_t                     result;
32
 
     char *                              dir_ptr = "";
33
 
 
34
 
 
35
 
@@ -2907,8 +2909,8 @@
36
 
 
37
 
     if(in_url[0] != '/')
38
 
     {
39
 
-        tmp_ptr = getcwd(start_dir, PATH_MAX);
40
 
-        if(tmp_ptr == NULL)
41
 
+        result = GLOBUS_GSI_SYSCONFIG_GET_CURRENT_WORKING_DIR(&start_dir);
42
 
+        if(result != GLOBUS_SUCCESS)
43
 
         {
44
 
             /* just punt if the system call fails */
45
 
             return globus_libc_strdup(in_url);
46
 
@@ -2927,6 +2929,9 @@
47
 
     globus_free(dir_ptr);
48
 
     globus_free(tmp_path);
49
 
     
50
 
+    if (start_dir)
51
 
+        globus_free(start_dir);
52
 
+
53
 
     return tmp_ptr;
54
 
 }
55