This commit is contained in:
Florian Bruhin 2014-09-27 23:21:13 +02:00
parent 2d6d6b3528
commit c9d5928dce

View File

@ -147,7 +147,7 @@ def serialize(obj):
"""Serialize an object into a QByteArray.""" """Serialize an object into a QByteArray."""
data = QByteArray() data = QByteArray()
stream = QDataStream(data, QIODevice.WriteOnly) stream = QDataStream(data, QIODevice.WriteOnly)
stream << obj stream << obj # pylint: disable=pointless-statement
_check_qdatastream(stream) _check_qdatastream(stream)
return data return data
@ -155,7 +155,7 @@ def serialize(obj):
def deserialize(data, obj): def deserialize(data, obj):
"""Deserialize an object from a QByteArray.""" """Deserialize an object from a QByteArray."""
stream = QDataStream(data, QIODevice.ReadOnly) stream = QDataStream(data, QIODevice.ReadOnly)
stream >> obj stream >> obj # pylint: disable=pointless-statement
_check_qdatastream(stream) _check_qdatastream(stream)