diff options
| author | Andrew Higginson <at.higginson@gmail.com> | 2011-12-27 21:05:11 +0000 |
|---|---|---|
| committer | Andrew <at.higginson@gmail.com> | 2011-12-27 21:05:11 +0000 |
| commit | cb9093c7d864ef914d7b1fea6596108e4ac8aa04 (patch) | |
| tree | 649e08260294370b4e78d353127883d5f6977cc1 /src | |
| parent | merged with trunk so I can build again... (diff) | |
| download | inkscape-cb9093c7d864ef914d7b1fea6596108e4ac8aa04.tar.gz inkscape-cb9093c7d864ef914d7b1fea6596108e4ac8aa04.zip | |
fixed crash!
(bzr r10092.1.37)
Diffstat (limited to 'src')
| -rw-r--r-- | src/ui/dialog/ocaldialogs.cpp | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/src/ui/dialog/ocaldialogs.cpp b/src/ui/dialog/ocaldialogs.cpp index db3d1272a..3ec1f687e 100644 --- a/src/ui/dialog/ocaldialogs.cpp +++ b/src/ui/dialog/ocaldialogs.cpp @@ -636,8 +636,10 @@ void ImportDialog::on_list_results_selection_changed() pathlist = list_results->get_selection()->get_selected_rows(); std::vector<int> posArray(1); - printf("%s", "on_list_results_selection_changed\n"); - + // If nothing is selected, then return + if (((int) pathlist.size()) < 1) { + return; + } posArray = pathlist[0].get_indices(); int row = posArray[0]; @@ -653,8 +655,10 @@ void ImportDialog::on_button_import_clicked() { pathlist = list_results->get_selection()->get_selected_rows(); std::vector<int> posArray(1); - printf("%s", "on_button_import_clicked\n"); - + // If nothing is selected, then return + if (((int) pathlist.size()) < 1) { + return; + } posArray = pathlist[0].get_indices(); int row = posArray[0]; @@ -674,8 +678,10 @@ void ImportDialog::on_list_results_cursor_changed() pathlist = list_results->get_selection()->get_selected_rows(); std::vector<int> posArray(1); - printf("%s", "on_list_results_cursor_changed\n"); - + // If nothing is selected, then return + if (((int) pathlist.size()) < 1) { + return; + } posArray = pathlist[0].get_indices(); int row = posArray[0]; |
