History

removed signed/unsigned comparisons

Andrew Meadows committed 12 years ago

Commit c089dbb1 parent e7b39ae1 file · +2 −2Browse files

Showing the changes to libraries/script-engine/src/TypedArrayPrototype.cpp (1 of 1 file). Show all

Unified · Split

libraries/script-engine/src/TypedArrayPrototype.cpp+2−2
@@ -30,11 +30,11 @@ void TypedArrayPrototype::set(QScriptValue array, qint32 offset) { · 29 unmodified lines
3030 engine()->evaluate("throw \"ArgumentError: negative offset\"");
3131 }
3232 quint32 length = array.property("length").toInt32();
33− if (offset + length > thisObject().data().property(typedArray->_lengthName).toInt32()) {
33+ if (offset + (qint32)length > thisObject().data().property(typedArray->_lengthName).toInt32()) {
3434 engine()->evaluate("throw \"ArgumentError: array does not fit\"");
3535 return;
3636 }
37− for (int i = 0; i < length; ++i) {
37+ for (quint32 i = 0; i < length; ++i) {
3838 thisObject().setProperty(QString::number(offset + i), array.property(QString::number(i)));
3939 }
4040 } else {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t