office-gobmx/libwps/libwps.gcc.warnings.patch
Michael Stahl 573af9266c libwps: fix gcc warning too [-Wsign-promo]
Change-Id: I23e32cfc100441530691e0dcdc71eac37b3fbf0d
2012-10-29 14:56:04 +01:00

15 lines
550 B
Diff
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

warning: passing libwps::Justification chooses int over unsigned int
diff -ru wps.old/src/lib/WPSParagraph.cpp wps/src/lib/WPSParagraph.cpp
--- wps.old/src/lib/WPSParagraph.cpp 2012-10-29 14:44:09.135977333 +0100
+++ wps/src/lib/WPSParagraph.cpp 2012-10-29 14:44:13.649981497 +0100
@@ -137,7 +137,8 @@
o << "just=fullAllLines, ";
break;
default:
- o << "just=" << pp.m_justify << ", ";
+ assert(false); // unhandled Justification enum value
+ o << "just=" << static_cast<unsigned>(pp.m_justify) << ", ";
break;
}