diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2017-02-05 16:04:35 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2017-02-05 16:04:35 +0000 |
| commit | 349536d49558ec5841e799eb33a4cbbb3fa9722d (patch) | |
| tree | 7e6a4cb6e7ecff3a3d81e99a8c3c3a246839a195 /src/uri.cpp | |
| parent | CMake: Supress status messages for install target on Windows (considerably sp... (diff) | |
| download | inkscape-349536d49558ec5841e799eb33a4cbbb3fa9722d.tar.gz inkscape-349536d49558ec5841e799eb33a4cbbb3fa9722d.zip | |
Fix C++11 errors and warnings with g++-7
Fixed bugs:
- https://launchpad.net/bugs/1660992
(bzr r15477)
Diffstat (limited to 'src/uri.cpp')
| -rw-r--r-- | src/uri.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/uri.cpp b/src/uri.cpp index f2578b989..9178c8ae8 100644 --- a/src/uri.cpp +++ b/src/uri.cpp @@ -8,11 +8,13 @@ * Released under GNU GPL, read the file 'COPYING' for more information */ -#include <glib.h> #include "uri.h" + #include <glibmm/ustring.h> #include <glibmm/miscutils.h> +#include "bad-uri-exception.h" + namespace Inkscape { URI::URI() { @@ -25,7 +27,7 @@ URI::URI(const URI &uri) { _impl = uri._impl; } -URI::URI(gchar const *preformed) throw(BadURIException) { +URI::URI(gchar const *preformed) { xmlURIPtr uri; if (!preformed) { throw MalformedURIException(); @@ -132,7 +134,7 @@ const gchar *URI::Impl::getOpaque() const { return (gchar *)_uri->opaque; } -gchar *URI::to_native_filename(gchar const* uri) throw(BadURIException) +gchar *URI::to_native_filename(gchar const* uri) { gchar *filename = NULL; URI tmp(uri); @@ -166,7 +168,7 @@ const std::string URI::getFullPath(std::string const &base) const { /* TODO !!! proper error handling */ -gchar *URI::toNativeFilename() const throw(BadURIException) { +gchar *URI::toNativeFilename() const { gchar *uriString = toString(); if (isRelativePath()) { return uriString; @@ -181,7 +183,7 @@ gchar *URI::toNativeFilename() const throw(BadURIException) { } } -URI URI::fromUtf8( gchar const* path ) throw (BadURIException) { +URI URI::fromUtf8( gchar const* path ) { if ( !path ) { throw MalformedURIException(); } @@ -215,7 +217,7 @@ URI URI::fromUtf8( gchar const* path ) throw (BadURIException) { } /* TODO !!! proper error handling */ -URI URI::from_native_filename(gchar const *path) throw(BadURIException) { +URI URI::from_native_filename(gchar const *path) { gchar *uri = g_filename_to_uri(path, NULL, NULL); URI result(uri); g_free( uri ); |
