Use QList::mid when constructing QStringList (#365)
The constructor with two iterators is too cutting edge from 5.14 to be widely supported right now
This commit is contained in:
parent
ca88bd92fb
commit
4d02cc8d68
@ -5,7 +5,7 @@ AOPacket::AOPacket(QString p_packet_string)
|
|||||||
QStringList packet_contents = p_packet_string.split("#");
|
QStringList packet_contents = p_packet_string.split("#");
|
||||||
|
|
||||||
m_header = packet_contents.first();
|
m_header = packet_contents.first();
|
||||||
m_contents = QStringList(packet_contents.begin()+1, packet_contents.end()-1); // trims %
|
m_contents = packet_contents.mid(1, packet_contents.size()-2); // trims %
|
||||||
}
|
}
|
||||||
|
|
||||||
QString AOPacket::to_string()
|
QString AOPacket::to_string()
|
||||||
|
Loading…
Reference in New Issue
Block a user