[pdfmod] Fix being able to load files with : in their path (bgo#631456)



commit 0979a2fd2fddd92105c48807104f8dcb51fef4bf
Author: Gabriel Burt <gabriel burt gmail com>
Date:   Wed Oct 6 14:46:16 2010 -0500

    Fix being able to load files with : in their path (bgo#631456)
    
    The Hyena dependency is bumped to 0.5, which was just released.

 configure.ac               |    4 ++--
 src/PdfMod/Core/Client.cs  |    1 +
 src/PdfMod/Pdf/Document.cs |    3 ++-
 3 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 51204d4..e55b8be 100644
--- a/configure.ac
+++ b/configure.ac
@@ -111,13 +111,13 @@ PKG_CHECK_MODULES([GLIB_SHARP_20], [glib-sharp-2.0])
 PKG_CHECK_MODULES([GCONF_SHARP_20], [gconf-sharp-2.0])
 
 dnl package checks, per config
-PKG_CHECK_MODULES(HYENA, hyena >= 0.3)
+PKG_CHECK_MODULES(HYENA, hyena >= 0.5)
 HYENA_ASSEMBLIES="`$PKG_CONFIG --variable=Assemblies hyena`"
 HYENA_FILES="`$PKG_CONFIG --variable=Files hyena`"
 AC_SUBST(HYENA_ASSEMBLIES)
 AC_SUBST(HYENA_FILES)
 
-PKG_CHECK_MODULES(HYENA_GUI, hyena.gui >= 0.3)
+PKG_CHECK_MODULES(HYENA_GUI, hyena.gui >= 0.5)
 HYENA_GUI_ASSEMBLIES="`$PKG_CONFIG --variable=Assemblies hyena.gui`"
 HYENA_GUI_FILES="`$PKG_CONFIG --variable=Files hyena.gui`"
 AC_SUBST(HYENA_GUI_ASSEMBLIES)
diff --git a/src/PdfMod/Core/Client.cs b/src/PdfMod/Core/Client.cs
index 591009d..e8d4d11 100644
--- a/src/PdfMod/Core/Client.cs
+++ b/src/PdfMod/Core/Client.cs
@@ -71,6 +71,7 @@ namespace PdfMod.Core
         public void LoadPath (string path, string suggestedFilename)
         {
             LoadPath (path, suggestedFilename, null);
+            Log.DebugFormat ("Loaded {0}", path);
         }
 
         public abstract void LoadPath (string path, string suggestedFilename, System.Action finishedCallback);
diff --git a/src/PdfMod/Pdf/Document.cs b/src/PdfMod/Pdf/Document.cs
index 8082fa6..1f92b18 100644
--- a/src/PdfMod/Pdf/Document.cs
+++ b/src/PdfMod/Pdf/Document.cs
@@ -140,7 +140,8 @@ namespace PdfMod.Pdf
                 tmp_path = new Uri (uri).LocalPath;
             }
 
-            var uri_obj = new Uri (uri);
+            var safe_uri = new Hyena.SafeUri (uri);
+            var uri_obj = new Uri (safe_uri.AbsoluteUri);
             Uri = uri_obj.AbsoluteUri;
             SuggestedSavePath = Path = uri_obj.LocalPath;
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]