[Marble-devel] QIODevice::write: device not open
Knut Schleßelmann
knut.krause at lagom.de
Thu Mar 13 08:57:03 UTC 2014
OK, now I didn't open the Device myself :-P
QDebug mDebug()
{
if ( MarbleDebug::isEnabled() ) {
return QDebug( QtDebugMsg );
}
else {
QFile *nullDevice = new QFile(QProcess::nullDevice());
nullDevice->open(QIODevice::WriteOnly);
return QDebug(nullDevice);
}
}
fixes the QIODevice messages. I don't know if this is a proper patch and I
don't know if your NullDevice does anything useful. Maybe this would make it
obsolete ;-)
Knut
Am Donnerstag, 13. März 2014, 08:02:55 schrieb Knut Schleßelmann:
> Hi there,
>
> I'm usinng marble as a Qt5 build from git and everything is working fine so
> far except that marble throws A LOT of "QIODevice::write: device not open"
> while I use it. It's so annoying I cannot use qDebug() in my code any more
> because every message will vanish immediately :-/
>
> I tried to figure out where those messages come from and my best guess is
> the marble debug function where it uses this NullDevice. I tried to change
> it so something like
>
> return QDebug(new QFile(QProcess::nullDevice()));
>
> in the else part but it still results in those messages :-/
>
> Anyone an idea how I (or even better everyone) could get rid of those
> messages?
>
>
> Knut
> _______________________________________________
> Marble-devel mailing list
> Marble-devel at kde.org
> https://mail.kde.org/mailman/listinfo/marble-devel
More information about the Marble-devel
mailing list