summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: bd792d4)
raw | patch | inline | side by side (parent: bd792d4)
author | theAdib <theAdib@users.sourceforge.net> | |
Wed, 29 Apr 2009 20:37:10 +0000 (20:37 +0000) | ||
committer | theAdib <theAdib@users.sourceforge.net> | |
Wed, 29 Apr 2009 20:37:10 +0000 (20:37 +0000) |
src/file.cpp | patch | blob | history |
diff --git a/src/file.cpp b/src/file.cpp
index 0bc68f86269c8db7777400a9594704a3e1180368..f8d631455fd48d36e499e6748920f2a3ca550623 100644 (file)
--- a/src/file.cpp
+++ b/src/file.cpp
// what gets passed here is not actually an URI... it is an UTF-8 encoded filename (!)
static void sp_file_add_recent(gchar const *uri)
{
+ if(uri == NULL) {
+ g_warning("sp_file_add_recent: uri == NULL");
+ return;
+ }
GtkRecentManager *recent = gtk_recent_manager_get_default();
gchar *fn = g_filename_from_utf8(uri, -1, NULL, NULL, NULL);
if (fn) {
success = file_save(parentWindow, doc, fileName, selectionType, TRUE, !is_copy);
- if (success) {
+ if (success && SP_DOCUMENT_URI(doc)) {
sp_file_add_recent(SP_DOCUMENT_URI(doc));
}
export_path = export_path_local;
//# Show the SaveAs dialog
- Inkscape::UI::Dialog::FileExportDialog *exportDialogInstance =
+ Inkscape::UI::Dialog::FileExportDialog *exportDialogInstance =
Inkscape::UI::Dialog::FileExportDialog::create(
export_path,
Inkscape::UI::Dialog::EXPORT_TYPES,