r20816 by jghali -

scribus-commit scribus-commit at lists.scribus.net
Sat Jan 30 22:24:09 UTC 2016


Author: jghali
Date: Sat Jan 30 22:24:09 2016
New Revision: 20816

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=20816
Log:
coverity #1350537: unintentional integer overflow

Modified:
    trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp

Modified: trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20816&path=/trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp	(original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp	Sat Jan 30 22:24:09 2016
@@ -693,7 +693,7 @@
 
 static long long scribus12itemID(int itemNr, int pageNr)
 {
-	return itemNr * 100000 + pageNr; 
+	return 100000 * ((long long) itemNr) + pageNr; 
 }
 
 bool Scribus12Format::loadFile(const QString & fileName, const FileFormat & /* fmt */, int /* flags */, int /* index */)




More information about the scribus-commit mailing list