Don't use the QRegExp methods that modify the object
authorThiago Macieira <thiago.macieira@intel.com>
Mon, 23 Apr 2012 14:47:50 +0000 (16:47 +0200)
committerQt by Nokia <qt-info@nokia.com>
Wed, 25 Apr 2012 19:05:49 +0000 (21:05 +0200)
commit11d0f7827fa8b20c7a084a184e70b90e1e0aeaea
tree2c2cbb047c7a50daf9eb2cd97e5c9ec6fc6248e2
parent87327515d70f5b66ce5f3f894f9b90ed649b200d
Don't use the QRegExp methods that modify the object

QRegExp matching methods modify the object, which we don't want to. In
particular, when we receive a QRegExp from the user or we store in a
context that might require thread-safety, make sure we make a copy
before using it.

QRegularExpression has no such shortcoming.

Task-number: QTBUG-25064
Change-Id: I252d1c47d7039caacec6aac5b572371d5b7efe32
Reviewed-by: Giuseppe D'Angelo <dangelog@gmail.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
src/quick/items/qquickdroparea.cpp