From d2b58ce026acede18e29bfa0d8046193bbe7d754 Mon Sep 17 00:00:00 2001 From: pjrm Date: Thu, 11 Oct 2007 14:05:24 +0000 Subject: [PATCH] (noop): io/uristream.cpp: Remove some unneeded gchar/char casts. Change constness of a couple of local vars to avoid some more casts (that were casting away constness). --- src/io/uristream.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/io/uristream.cpp b/src/io/uristream.cpp index e06498d52..9787620db 100644 --- a/src/io/uristream.cpp +++ b/src/io/uristream.cpp @@ -105,19 +105,19 @@ UriInputStream::UriInputStream(Inkscape::URI &source) throw (StreamException): uri(source) { //get information from uri - char *schemestr = (char *) uri.getScheme(); + char const *schemestr = uri.getScheme(); scheme = SCHEME_FILE; if (!schemestr || strncmp("file", schemestr, 4)==0) scheme = SCHEME_FILE; else if (strncmp("data", schemestr, 4)==0) scheme = SCHEME_DATA; //printf("in schemestr:'%s' scheme:'%d'\n", schemestr, scheme); - char *cpath = NULL; + gchar *cpath = NULL; switch (scheme) { case SCHEME_FILE: - cpath = (char *) uri.toNativeFilename(); + cpath = uri.toNativeFilename(); //printf("in cpath:'%s'\n", cpath); inf = fopen_utf8name(cpath, FILE_READ); //inf = fopen(cpath, "rb"); @@ -317,18 +317,18 @@ UriOutputStream::UriOutputStream(Inkscape::URI &destination) scheme(SCHEME_FILE) { //get information from uri - char *schemestr = (char *) uri.getScheme(); + char const *schemestr = uri.getScheme(); if (!schemestr || strncmp("file", schemestr, 4)==0) scheme = SCHEME_FILE; else if (strncmp("data", schemestr, 4)==0) scheme = SCHEME_DATA; //printf("out schemestr:'%s' scheme:'%d'\n", schemestr, scheme); - char *cpath = NULL; + gchar *cpath = NULL; switch (scheme) { case SCHEME_FILE: - cpath = (char *) uri.toNativeFilename(); + cpath = uri.toNativeFilename(); //printf("out path:'%s'\n", cpath); outf = fopen_utf8name(cpath, FILE_WRITE); //outf = fopen(cpath, "wb"); -- 2.30.2