summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ui/documentwidget.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c
index 68f3c966..87a55dcb 100644
--- a/src/ui/documentwidget.c
+++ b/src/ui/documentwidget.c
@@ -2005,8 +2005,14 @@ static iBool handleCommand_DocumentWidget_(iDocumentWidget *d, const char *cmd)
2005 /* Find links that aren't already bookmarked. */ 2005 /* Find links that aren't already bookmarked. */
2006 iForEach(PtrArray, i, links) { 2006 iForEach(PtrArray, i, links) {
2007 const iGmRun *run = i.ptr; 2007 const iGmRun *run = i.ptr;
2008 if (findUrl_Bookmarks(bookmarks_App(), linkUrl_GmDocument(d->doc, run->linkId))) { 2008 uint32_t bmid;
2009 remove_PtrArrayIterator(&i); 2009 if ((bmid = findUrl_Bookmarks(bookmarks_App(),
2010 linkUrl_GmDocument(d->doc, run->linkId))) != 0) {
2011 const iBookmark *bm = get_Bookmarks(bookmarks_App(), bmid);
2012 /* We can import local copies of remote bookmarks. */
2013 if (!hasTag_Bookmark(bm, "remote")) {
2014 remove_PtrArrayIterator(&i);
2015 }
2010 } 2016 }
2011 } 2017 }
2012 if (!isEmpty_PtrArray(links)) { 2018 if (!isEmpty_PtrArray(links)) {