[librsvg] rsvg-base.c: Have realpath() Work On Windows
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [librsvg] rsvg-base.c: Have realpath() Work On Windows
- Date: Wed,  3 Dec 2014 09:38:37 +0000 (UTC)
commit e60c00f6e92bf6ce4b64c130319e300147f95286
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Mon Aug 18 12:27:28 2014 +0800
    rsvg-base.c: Have realpath() Work On Windows
    
    Use _fullpath() on Windows to do the job for realpath() as realpath() does
    not exist on Windows.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=710163
    
    Signed-off-by: Richard Hughes <richard hughsie com>
 rsvg-base.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/rsvg-base.c b/rsvg-base.c
index 683d607..c40669a 100644
--- a/rsvg-base.c
+++ b/rsvg-base.c
@@ -58,6 +58,15 @@
 #include "rsvg-xml.h"
 
 /*
+ * XXX: Perhaps do a GIO-based implementation for
+ * realpath() or use gnulib implementation for this
+ * https://bugzilla.gnome.org/show_bug.cgi?id=710163
+ */
+#ifdef G_OS_WIN32
+#define realpath(a,b) _fullpath(b,a,_MAX_PATH)
+#endif
+
+/*
  * This is configurable at runtime
  */
 #define RSVG_DEFAULT_DPI_X 90.0
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]