List:MySQL++« Previous MessageNext Message »
From:Kevin Regan Date:April 4 2005 9:59pm
Subject:Patch to fix compile error.
View as plain text  
We are seeing the following compiler warning (we exit on warnings):

/usr/mysql/mysql++-1.7.32-1/include/null.h: In member function
   `mysqlpp::null_type::operator Type()':
/usr/mysql/mysql++-1.7.32-1/include/null.h:14: warning: no return statement in
   function returning non-void

Here is a patch to fix it:

--- lib/null.h	2005-03-15 21:25:23.000000000 -0800
+++ lib/null.h.f5	2005-03-15 21:25:09.000000000 -0800
@@ -11,7 +11,7 @@
 
 class null_type {
 public:
-  template <class Type> operator Type () {throw BadNullConversion();}
+  template <class Type> operator Type () {if (1) throw BadNullConversion();else
return Type();}
 };
 
 //: 

Sincerely,
Kevin Regan
k.regan@stripped


Thread
Patch to fix compile error.Kevin Regan4 Apr
  • Re: Patch to fix compile error.Warren Young5 Apr
RE: Patch to fix compile error.Steve Roberts5 Apr
RE: Patch to fix compile error.Kevin Regan5 Apr
RE: Patch to fix compile error.Kevin Regan5 Apr
  • Re: Patch to fix compile error.Warren Young5 Apr