[koffice] fix for 'error: control reaches end of non-void function [-Werror=return-type]'

Rex Dieter rdieter at fedoraproject.org
Sun Feb 20 03:17:35 UTC 2011


commit a1ff41e3e962ec018bd7f75ec4836e6c68237071
Author: Rex Dieter <rdieter at fedoraproject.org>
Date:   Sat Feb 19 21:17:13 2011 -0600

    fix for 'error: control reaches end of non-void function [-Werror=return-type]'

 koffice-2.3.2-gcc46.patch |   23 +++++++++++++++++++++++
 koffice.spec              |    2 ++
 2 files changed, 25 insertions(+), 0 deletions(-)
---
diff --git a/koffice-2.3.2-gcc46.patch b/koffice-2.3.2-gcc46.patch
new file mode 100644
index 0000000..dcf8a4f
--- /dev/null
+++ b/koffice-2.3.2-gcc46.patch
@@ -0,0 +1,23 @@
+diff -up koffice-2.3.2/krita/plugins/formats/exr/exr_converter.cc.gcc46 koffice-2.3.2/krita/plugins/formats/exr/exr_converter.cc
+--- koffice-2.3.2/krita/plugins/formats/exr/exr_converter.cc.gcc46	2011-02-17 06:13:40.000000000 -0600
++++ koffice-2.3.2/krita/plugins/formats/exr/exr_converter.cc	2011-02-19 21:15:56.597142885 -0600
+@@ -80,6 +80,9 @@ ImageType imfTypeToKisType(Imf::PixelTyp
+         return IT_FLOAT16;
+     case Imf::FLOAT:
+         return IT_FLOAT32;
++    default:
++    // shouldn't reach here
++        return IT_UNSUPPORTED;
+     }
+ }
+ 
+@@ -93,6 +96,9 @@ const KoColorSpace* kisTypeToColorSpace(
+     case IT_UNKNOWN:
+     case IT_UNSUPPORTED:
+         return 0;
++    default:
++    // shouldn't reach here
++        return 0;
+     }
+ }
+ 
diff --git a/koffice.spec b/koffice.spec
index 8c1f2f6..07ba1f3 100644
--- a/koffice.spec
+++ b/koffice.spec
@@ -32,6 +32,7 @@ Source0:        http://download.kde.org/stable/koffice-%{version}/koffice-%{vers
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 ## upstreamable patches
+Patch50: koffice-2.3.2-gcc46.patch
 ## upstream patches
 
 # backport support for libwpg 0.2 from Calligra master:
@@ -494,6 +495,7 @@ Requires:       libxml2-devel
 
 %prep
 %setup -q
+%patch50 -p1 -b .gcc46
 %patch100 -p1 -b .libwpg02
 
 ## kdchart munging begin


More information about the scm-commits mailing list