Here cmd is int so I haven't made any changes. for listit I used qWarning() followed by abort(). Please review it.
On Wed, Jan 9, 2013 at 5:16 PM, David Faure <fa...@kde.org> wrote: > On Wednesday 09 January 2013 16:45:08 Jignesh Kakadiya wrote: > > Hi David, > > > > I have ported all kError calls to qWarning and kFatal to qFatal in > > kdelibs/kio/kio directory. Compiles successfully. Please review it. > > > > Next patch will be removal of kdebug.h include from kio/kio. > > qFatal("Fatal Error: Got cmd %s, while waiting for an answer!", cmd); > > I doubt that cmd is a char*. If it's a QString, use qPrintable(cmd), if > it's a > QByteArray, use cmd.constData(). > Otherwise it compiles, but with a compiler warning (cannot pass a POD to > "...") and it will crash at runtime (OK, for qFatal we expect a crash, but > it > helps if we can see the message first :-) > > > + qFatal() << "HUH? Lister" << listit << "is supposed to be listing, > but has no job!"; > > This one won't compile. You didn't notice because it's inside #if 0, but it > should be fixed for whenever a developer re-enables that code. If qFatal > is too > cumbersome to use, you could use qWarning() followed by abort, for > instance. > > -- > David Faure, fa...@kde.org, http://www.davidfaure.fr > Working on KDE, in particular KDE Frameworks 5 > >
kError_and_kFatal.patch
Description: Binary data
_______________________________________________ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel