generic: misc cleanups

This commit is contained in:
Ivailo Monev 2015-08-19 05:07:27 +03:00
parent 1a0dfb4704
commit 8699660085
3 changed files with 3 additions and 9 deletions

View file

@ -61,9 +61,10 @@ KSycocaFactory::KSycocaFactory(KSycocaFactoryId factory_id)
d->m_endEntryOffset = i;
QDataStream* str = stream();
int saveOffset = str->device()->pos();
// Init index tables
d->m_sycocaDict = new KSycocaDict(str, d->m_sycocaDictOffset);
str->device()->seek(str->device()->pos());
saveOffset = str->device()->seek(saveOffset);
} else {
// We are in kbuildsycoca4 -- build new database!
m_entryDict = new KSycocaEntryDict;

View file

@ -272,14 +272,6 @@ KStyle::KStyle() : clickedLabel(0), d(new KStylePrivate)
KStyle::~KStyle()
{
// this is just for stupid msvc compiler to force the creation of
// DoubleButtonOption::defaultOption() inside kstyle lib
// hope the optimizer won't throw it away
const DoubleButtonOption* bOpt = extractOption<const DoubleButtonOption*>(NULL);
Q_UNUSED(bOpt)
#ifdef __GNUC__
#warning "mem leak: need to delete bOpt"
#endif
delete d;
}

View file

@ -4,3 +4,4 @@
#cmakedefine HAVE___PROGNAME_FULL 1
#cmakedefine HAVE_SYS_PSTAT_H 1
#cmakedefine HAVE_PSTAT 1
#cmakedefine HAVE_SETPROCTITLE 1