Hi,

I'm using Qt 4.3.0 on Windows with Visual Studio 2003 .NET.

I have a QHash defined as:
Qt Code:
  1. QHash<QString,QVariant> m_qHash;
To copy to clipboard, switch view to plain text mode 

The "m_qHash" containg 16 elements.

Then I use a QDataStream to store it to a file.
When trying to load from the file, the first value(hash pair) is correctly loaded,but it crash on "QDataStream &operator>>(QDataStream &in, QString &str)" into "qstring.cpp", when reading the second value(hash pair). When it reads the "bytes" on line 6829, it reads that it contains 0 bytes and so it returns an empty string.
Then on "QDataStream& operator>>(QDataStream &s, QVariant &p)" into "qvariant.cpp" crash on line 1775:

Qt Code:
  1. Q_ASSERT_X(false, "QVariant::load", "Invalid type to load");
To copy to clipboard, switch view to plain text mode 

I'm debugging the application and I don't find where is the problem.

Thanks,