summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2022-04-04 15:06:36 +0200
committerMarc Mutz <marc.mutz@qt.io>2022-04-05 13:47:16 +0200
commitfa67208f8f864e2269ea3668031cc44006feb984 (patch)
tree32b1b6cab5f14f36322a84593c8b94801c61e9ab
parent5d6d1272718a817c118fe09b784e2de508f95e6b (diff)
QBufferPrivate: use NSDMI
Removes some #ifdef'ery. Also remove the unneeded dtor. While this is a polymophic class, it's not in a header, so we won't run into the scenario described in QTBUG-45582. Pick-to: 6.3 Change-Id: I1a8598402ff2a564cc53da2f85ed3ed00ca3ddbf Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
-rw-r--r--src/corelib/io/qbuffer.cpp16
1 files changed, 5 insertions, 11 deletions
diff --git a/src/corelib/io/qbuffer.cpp b/src/corelib/io/qbuffer.cpp
index 8bf51709bc..3da76a35fb 100644
--- a/src/corelib/io/qbuffer.cpp
+++ b/src/corelib/io/qbuffer.cpp
@@ -49,15 +49,9 @@ class QBufferPrivate : public QIODevicePrivate
Q_DECLARE_PUBLIC(QBuffer)
public:
- QBufferPrivate()
- : buf(nullptr)
-#ifndef QT_NO_QOBJECT
- , writtenSinceLastEmit(0), signalConnectionCount(0), signalsEmitted(false)
-#endif
- { }
- ~QBufferPrivate() { }
+ QBufferPrivate() = default;
- QByteArray *buf;
+ QByteArray *buf = nullptr;
QByteArray defaultBuf;
qint64 peek(char *data, qint64 maxSize) override;
@@ -67,9 +61,9 @@ public:
// private slots
void _q_emitSignals();
- qint64 writtenSinceLastEmit;
- int signalConnectionCount;
- bool signalsEmitted;
+ qint64 writtenSinceLastEmit = 0;
+ int signalConnectionCount = 0;
+ bool signalsEmitted = false;
#endif
};