Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 14 Apr 2018 07:12:29 +0000 (UTC)
From:      "Tobias C. Berner" <tcberner@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r467292 - head/deskutils/fbreader/files
Message-ID:  <201804140712.w3E7CTEL077657@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tcberner
Date: Sat Apr 14 07:12:29 2018
New Revision: 467292
URL: https://svnweb.freebsd.org/changeset/ports/467292

Log:
  deskutils/fbreader: Fix build with Clang 6
  
  PR:		227125
  Submitted by:	Peter Kien <peter.kien@posteo.org>
  Approved by:	xmj (maintainer)

Added:
  head/deskutils/fbreader/files/patch-fbreader_src_database_booksdb_BooksDB.cpp   (contents, props changed)

Added: head/deskutils/fbreader/files/patch-fbreader_src_database_booksdb_BooksDB.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/deskutils/fbreader/files/patch-fbreader_src_database_booksdb_BooksDB.cpp	Sat Apr 14 07:12:29 2018	(r467292)
@@ -0,0 +1,25 @@
+BooksDB.cpp:148:10: error: no viable conversion from returned value of type 'bool' to function return type 'shared_ptr<Book>'
+                return false;
+                       ^~~~~
+/wrkdirs/usr/ports/deskutils/fbreader/work/FBReader-0.99.6-freebsdport/fbreader/../zlibrary/core/include/shared_ptr.h:57:3: note: candidate constructor not viable: no known conversion from 'bool' to 'Book *' for 1st argument
+                shared_ptr(T *t);
+                ^
+/wrkdirs/usr/ports/deskutils/fbreader/work/FBReader-0.99.6-freebsdport/fbreader/../zlibrary/core/include/shared_ptr.h:58:3: note: candidate constructor not viable: no known conversion from 'bool' to 'const shared_ptr<Book> &' for 1st argument
+                shared_ptr(const shared_ptr<T> &t);
+                ^
+/wrkdirs/usr/ports/deskutils/fbreader/work/FBReader-0.99.6-freebsdport/fbreader/../zlibrary/core/include/shared_ptr.h:59:3: note: candidate constructor not viable: no known conversion from 'bool' to 'const weak_ptr<Book> &' for 1st argument
+                shared_ptr(const weak_ptr<T> &t);
+                ^
+1 error generated.
+
+--- fbreader/src/database/booksdb/BooksDB.cpp.orig	2014-01-11 12:45:25 UTC
++++ fbreader/src/database/booksdb/BooksDB.cpp
+@@ -145,7 +145,7 @@ shared_ptr<Book> BooksDB::loadBook(const std::string &
+
+ 	myFindFileId->setFileName(fileName);
+ 	if (!myFindFileId->run()) {
+-		return false;
++		return 0;
+ 	}
+ 	((DBIntValue&)*myLoadBook->parameter("@file_id").value()) = myFindFileId->fileId();
+ 	shared_ptr<DBDataReader> reader = myLoadBook->executeReader();



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201804140712.w3E7CTEL077657>