Bugzilla – Attachment 211965 Details for
Bug 382703
sax2: yast2 live-installer segfaults
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Forgot Password
[patch]
sax2.diff
sax2.diff (text/plain), 20.13 KB, created by
Marcus Schaefer
on 2008-05-02 12:09:15 UTC
(
hide
)
Description:
sax2.diff
Filename:
MIME Type:
Creator:
Marcus Schaefer
Created:
2008-05-02 12:09:15 UTC
Size:
20.13 KB
patch
obsolete
>Index: libsax/pointers.cpp >=================================================================== >--- libsax/pointers.cpp (revision 1581) >+++ libsax/pointers.cpp (working copy) >@@ -229,7 +229,8 @@ > //! concerning the type of the pointer device > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Device"); > } >@@ -242,7 +243,8 @@ > //! return the driver used for this pointer device > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Driver"); > } >@@ -255,7 +257,8 @@ > //! return the protocol used for this pointer device > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Protocol"); > } >@@ -272,7 +275,8 @@ > //! (bool options) the value for the key is the (null) string > // ---- > if (! mImport) { >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > Q3Dict<QString> result; > QString stdOptions = mImport -> getItem ("Option"); >@@ -963,7 +967,8 @@ > //! return the CDB model name of this tablet > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Name"); > } >@@ -976,7 +981,8 @@ > //! return the CDB vendor name of this tablet > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Vendor"); > } >@@ -990,7 +996,8 @@ > //! can be: cursor,stylus or eraser > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("TabletType"); > } >@@ -1004,7 +1011,8 @@ > //! can be either Absolute or Relative > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("TabletMode"); > } >@@ -1053,7 +1061,8 @@ > if (opts.isEmpty()) { > excCDBRecordNotFound (driver); > qError (errorString(),EXC_CDBRECORDNOTFOUND); >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > mCDBTabletOptions = *opts.at(0); > return mCDBTabletOptions; >@@ -1551,7 +1560,8 @@ > //! separated by a semi-colon > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QString name = mImport -> getItem ("Name"); > QStringList vnlist = QStringList::split ( ";", name ); >@@ -1568,7 +1578,8 @@ > //! separated by a semi-colon > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QString name = mImport -> getItem ("Name"); > QStringList vnlist = QStringList::split ( ";", name ); >@@ -1585,7 +1596,8 @@ > //! is handled with the same key: TabletType > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("TabletType"); > } >Index: libsax/storage.cpp >=================================================================== >--- libsax/storage.cpp (revision 1581) >+++ libsax/storage.cpp (working copy) >@@ -115,7 +115,8 @@ > //! to the current data record > // ---- > if (! mData.at (mCurrentID) -> operator[] (key)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return *mData.at (mCurrentID) -> operator[] (key); > } >@@ -386,7 +387,8 @@ > if (mData.at (id)) { > return *mData.at (id); > } else { >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > } > >Index: libsax/desktop.cpp >=================================================================== >--- libsax/desktop.cpp (revision 1581) >+++ libsax/desktop.cpp (working copy) >@@ -284,7 +284,8 @@ > //! method will return an empty QString > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //=================================== > // Check SaXMeta data... >@@ -311,7 +312,8 @@ > SaXImportSysp* pCard = new SaXImportSysp (SYSP_CARD); > pCard -> doImport(); > if (! pCard -> setID ( mDesktopID )) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QString mCardName; > QTextOStream (&mCardName) << >@@ -351,7 +353,8 @@ > //------------------------------------ > excEmptyCDBGroup ( mCardName.latin1() ); > qError (errorString(),EXC_EMPTYCDBGROUP); >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > > //==================================== >@@ -933,13 +936,15 @@ > //! color an empty list is returned > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString modes; > modes.sprintf ("Modes:%d",color); > QString resolutions = mDesktop -> getItem (modes); > if (resolutions.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList resList = QStringList::split ( ",", resolutions ); >@@ -960,7 +965,8 @@ > //! the resolution > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> defaultList; > defaultList.append (QString("800x600")); >@@ -1056,10 +1062,12 @@ > desktop -> setID ( mDesktopID ); > desktop -> doImport (); > if ( desktop->getItem(key).isNull()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > if ((key != "FBBoot") && (desktop->getItem("DDC") == "<undefined>")) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString val = desktop->getItem(key); > QStringList items = QStringList::split ( ",", val ); >@@ -1119,11 +1127,13 @@ > //! returned > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString size = mDesktop -> getItem ("DisplaySize"); > if (size.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList sizeList = QStringList::split ( " ", size ); >@@ -1145,11 +1155,13 @@ > //! from the getDisplaySize() method > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QList<QString> size = getDisplaySize(); > if (size.isEmpty()) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > int x = size.at(0).toInt(); > int y = size.at(1).toInt(); >@@ -1168,14 +1180,16 @@ > //! information from the getDisplaySize() method > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString* setX = new QString ("4"); > QString* setY = new QString ("3"); > QList<QString> result; > QList<QString> size = getDisplaySize(); > if (size.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > int x = size.at(0).toInt(); > int y = size.at(1).toInt(); >@@ -1205,11 +1219,13 @@ > //! value specify the end of the range > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString range = mDesktop -> getItem ("HorizSync"); > if (range.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList rangeList = QStringList::split ( "-", range ); >@@ -1232,11 +1248,13 @@ > //! value specify the end of the range > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString range = mDesktop -> getItem ("VertRefresh"); > if (range.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList rangeList = QStringList::split ( "-", range ); >@@ -1277,7 +1295,8 @@ > //! currently selected desktop > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mDesktop -> getItem ("VendorName"); > } >@@ -1291,7 +1310,8 @@ > //! currently selected desktop > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mDesktop -> getItem ("ModelName"); > } >@@ -1305,7 +1325,8 @@ > //! the active desktop > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mDesktop -> getItem ("ColorDepth"); > } >@@ -1318,7 +1339,8 @@ > //! get the currently used modeline algorithm method > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mDesktop -> getItem ("CalcAlgorithm"); > } >@@ -1351,14 +1373,16 @@ > //! string is returned > // ---- > if ((! mDesktop) || (! mCard) || (! mPath)) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QString key; > QString val; > key.sprintf ("Virtual:%d",color); > val = mDesktop -> getItem (key); > if (val.isEmpty()) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > QStringList resList = QStringList::split ( " ", val ); > QString result (resList.join("x")); >Index: libsax/layout.cpp >=================================================================== >--- libsax/layout.cpp (revision 1581) >+++ libsax/layout.cpp (working copy) >@@ -280,7 +280,8 @@ > // ---- > SaXManipulateCard cardData (mCard); > if (! cardData.selectCard (screen)) { >- return QList<QString> (); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString idString; idString.sprintf ("%d",screen); > QString layout = mLayout -> getItem ( >@@ -289,7 +290,8 @@ > if (layout.isEmpty()) { > excGetScreenLayoutFailed (screen); > qError (errorString(),EXC_GETSCREENLAYOUTFAILED); >- return QList<QString> (); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> layoutList; > QStringList positions = QStringList::split ( " ", layout ); >@@ -311,7 +313,8 @@ > if (layout.isEmpty()) { > excGetInputLayoutFailed (); > qError (errorString(),EXC_GETINPUTLAYOUTFAILED); >- return QList<QString> (); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> inputList; > QStringList tokens = QStringList::split ( ",", layout ); >Index: libsax/file.cpp >=================================================================== >--- libsax/file.cpp (revision 1581) >+++ libsax/file.cpp (working copy) >@@ -59,7 +59,8 @@ > //! with a "#" are allowed > // ---- > if (! mHandle -> isOpen()) { >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > char line[MAX_LINE_LENGTH]; > while ((mHandle->readLine(line,MAX_LINE_LENGTH)) != 0) { >Index: libsax/path.cpp >=================================================================== >--- libsax/path.cpp (revision 1581) >+++ libsax/path.cpp (working copy) >@@ -214,7 +214,8 @@ > //! this X11 configuration > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString paths = mImport -> getItem ("FontPath"); > return createList (paths); >@@ -229,7 +230,8 @@ > //! X11 configuration > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString modules = mImport -> getItem ("ModuleLoad"); > return createList (modules); >@@ -244,7 +246,8 @@ > //! X11 configuration > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString modules = mImport -> getItem ("ServerFlags"); > return createList (modules); >@@ -259,7 +262,8 @@ > //! empty items will be ignored using this method > // ---- > if (data.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList dataList = QStringList::split ( ",", data ); >Index: libsax/keyboard.cpp >=================================================================== >--- libsax/keyboard.cpp (revision 1581) >+++ libsax/keyboard.cpp (working copy) >@@ -113,7 +113,8 @@ > //! given baselayout. > // ---- > if ( layout.isEmpty() || ! getLayouts().find(layout) ) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result1; > QStringList* r1 = mVarLists[layout]; >@@ -445,7 +446,8 @@ > //! return the driver used for this keyboard device > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Driver"); > } >@@ -458,7 +460,8 @@ > //! return a list of XKB options set for the core keyboard > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString options = mImport -> getItem ("XkbOptions"); > return createList (options); >@@ -473,7 +476,8 @@ > //! the first element of the list os the core layout > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString layouts = mImport -> getItem ("XkbLayout"); > return createList (layouts); >@@ -488,7 +492,8 @@ > //! defined keyboard layouts > // ---- > if (! mImport) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QString variants = mImport -> getItem ("XkbVariant"); > return createList (variants); >@@ -505,13 +510,15 @@ > //! be throwed and an empty string is returned > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > int layoutCount = findLayout (layout); > if (layoutCount < 0) { > excXKBLayoutUndefined (layout); > qError (errorString(),EXC_XKBLAYOUTUNDEFINED); >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > int varCount = 0; > QList<QString> vList = getXKBVariantList(); >@@ -522,7 +529,8 @@ > } > varCount++; > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > > //==================================== >@@ -534,7 +542,8 @@ > //! keyboard. Only one model can be defined and active > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("XkbModel"); > } >@@ -574,7 +583,8 @@ > //! empty items (,,) are allowed using this method > // ---- > if (data.isEmpty()) { >- return QList<QString>(); >+ QList<QString>* nope = new QList<QString>; >+ return *nope; > } > QList<QString> result; > QStringList dataList = QStringList::split ( ",", data, true ); >Index: libsax/config.cpp >=================================================================== >--- libsax/config.cpp (revision 1581) >+++ libsax/config.cpp (working copy) >@@ -491,7 +491,8 @@ > //! error occured an empty string is returned > // ---- > if (mParseErrorValue->isEmpty()) { >- return QString(""); >+ QString* nope = new QString(""); >+ return *nope; > } > return *mParseErrorValue; > } >@@ -505,7 +506,8 @@ > //! error occured an empty string is returned > // ---- > if (mParseErrorString->isEmpty()) { >- return QString(""); >+ QString* nope = new QString(""); >+ return *nope; > } > return *mParseErrorString; > } >Index: libsax/card.cpp >=================================================================== >--- libsax/card.cpp (revision 1581) >+++ libsax/card.cpp (working copy) >@@ -265,7 +265,8 @@ > //! separated by a colon from the currently selected card > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // search name in SYSP data >@@ -296,7 +297,8 @@ > //! interface > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // search vendor in SYSP data >@@ -321,7 +323,8 @@ > //! interface > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // search model in SYSP data >@@ -346,7 +349,8 @@ > //! selected card > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("BusID"); > } >@@ -360,7 +364,8 @@ > //! selected card > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Driver"); > } >@@ -374,7 +379,8 @@ > //! selected card. This value is always 0 for non multihead cards > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Screen"); > } >@@ -389,7 +395,8 @@ > //! empty QString is returned > // ---- > if (! mImport) { >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > return mImport -> getItem ("Rotate"); > } >@@ -406,7 +413,8 @@ > //! (bool options) the value for the key is the (null) string > // ---- > if (! mImport) { >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > Q3Dict<QString> result; > QString stdOptions = mImport -> getItem ("Option"); >@@ -489,7 +497,8 @@ > if (opts.isEmpty()) { > excCDBRecordNotFound (driver); > qError (errorString(),EXC_CDBRECORDNOTFOUND); >- return Q3Dict<QString>(); >+ Q3Dict<QString>* nope = new Q3Dict<QString>; >+ return *nope; > } > Q3PtrList< Q3Dict<QString> > xaaopts; > xaaopts = mCDBCardModules -> getTablePointerCDB_DATA ( >Index: rpm/sax2.changes >=================================================================== >--- rpm/sax2.changes (revision 1584) >+++ rpm/sax2.changes (working copy) >@@ -1,4 +1,10 @@ > ------------------------------------------------------------------- >+Fri May 2 14:05:33 CEST 2008 - ms@suse.de >+ >+- fixed libsax and xapi object return values according >+ to qt3 -> qt4 changes (bnc #382703) >+ >+------------------------------------------------------------------- > Tue Apr 29 09:47:23 CEST 2008 - ms@suse.de > > - update hwinfo source, monitors added (bnc #373997) >Index: api/vnc/vncdisplay.cpp >=================================================================== >--- api/vnc/vncdisplay.cpp (revision 1581) >+++ api/vnc/vncdisplay.cpp (working copy) >@@ -278,7 +278,8 @@ > if (mCheckPWD -> isOn()) { > return mPWD1->text(); > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // slotActivateVNC >Index: api/tablet/tabletselection.cpp >=================================================================== >--- api/tablet/tabletselection.cpp (revision 1581) >+++ api/tablet/tabletselection.cpp (working copy) >@@ -141,7 +141,8 @@ > if (mVendorList->selectedItem()) { > return mVendorList->selectedItem()->text(); > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // getModel >@@ -150,7 +151,8 @@ > if (mModelList->selectedItem()) { > return mModelList->selectedItem()->text(); > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // slotVendor >Index: api/touchscreen/touchselection.cpp >=================================================================== >--- api/touchscreen/touchselection.cpp (revision 1581) >+++ api/touchscreen/touchselection.cpp (working copy) >@@ -268,7 +268,8 @@ > if (mVendorList->selectedItem()) { > return mVendorList->selectedItem()->text(); > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // getModel >@@ -277,7 +278,8 @@ > if (mModelList->selectedItem()) { > return mModelList->selectedItem()->text(); > } >- return QString(); >+ QString* nope = new QString; >+ return *nope; > } > //==================================== > // getPortName >Index: api/wrapper.h >=================================================================== >--- api/wrapper.h (revision 1581) >+++ api/wrapper.h (working copy) >@@ -43,7 +43,8 @@ > if (pM->operator[](key)) { > return(QString::fromLocal8Bit( *pM->operator[](key) )); > } >- return QString(""); >+ QString* nope = new QString; >+ return *nope; > } > void insert (const QString & key,QString* val) { > pM->insert (key,val);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 382703
:
209836
|
211682
|
211683
| 211965 |
213736