@@ -2448,9 +2448,14 @@ bool QtSoapMessage::setContent(const QByteArray &buffer)
24482448 if (!doc.setContent (buffer, true , &errorMsg,
24492449 &errorLine, &errorColumn)) {
24502450 QString s;
2451- s.sprintf (" %s at line %i, column %i" , errorMsg.toLatin1 ().constData (),
2452- errorLine, errorColumn);
2453- setFaultCode (VersionMismatch);
2451+ #if QT_VERSION < QT_VERSION_CHECK(5, 14, 0)
2452+ s.sprintf (" %s at line %i, column %i" , errorMsg.toLatin1 ().constData (),
2453+ errorLine, errorColumn);
2454+ #else
2455+ s = " %1 at line %2, column %3" ;
2456+ s = s.arg (errorMsg.toLatin1 ().constData ()).arg (errorLine).arg (errorColumn);
2457+ #endif
2458+ setFaultCode (VersionMismatch);
24542459 setFaultString (" XML parse error" );
24552460 addFaultDetail (new QtSoapSimpleType (QtSoapQName (" ParseError" ), s));
24562461 return false ;
@@ -2902,11 +2907,23 @@ void QtSoapMessage::addMethodArgument(const QString &name, const QString &uri, i
29022907QtSoapTypeFactory::QtSoapTypeFactory ()
29032908{
29042909 QtSoapTypeConstructor<QtSoapStruct> *structConstructor = new QtSoapTypeConstructor<QtSoapStruct>();
2910+ #if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
29052911 deleteList.append (structConstructor);
2912+ #else
2913+ deleteList.push_back (structConstructor);
2914+ #endif
29062915 QtSoapTypeConstructor<QtSoapArray> *arrayConstructor = new QtSoapTypeConstructor<QtSoapArray>();
2916+ #if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
29072917 deleteList.append (arrayConstructor);
2918+ #else
2919+ deleteList.push_back (arrayConstructor);
2920+ #endif
29082921 QtSoapTypeConstructor<QtSoapSimpleType> *basicTypeConstructor = new QtSoapTypeConstructor<QtSoapSimpleType>();
2922+ #if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
29092923 deleteList.append (basicTypeConstructor);
2924+ #else
2925+ deleteList.push_back (basicTypeConstructor);
2926+ #endif
29102927
29112928 registerHandler (" struct" , structConstructor);
29122929 registerHandler (" array" , arrayConstructor);
@@ -2947,7 +2964,11 @@ QtSoapTypeFactory::QtSoapTypeFactory()
29472964*/
29482965QtSoapTypeFactory::~QtSoapTypeFactory ()
29492966{
2950- QLinkedList<QtSoapTypeConstructorBase*>::ConstIterator it = deleteList.begin ();
2967+ #if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
2968+ QLinkedList<QtSoapTypeConstructorBase *>::ConstIterator it = deleteList.begin ();
2969+ #else
2970+ std::list<QtSoapTypeConstructorBase *>::const_iterator it = deleteList.begin ();
2971+ #endif
29512972 while (it != deleteList.end ()) {
29522973 delete *it;
29532974 ++it;
0 commit comments