View Issue Details

IDProjectCategoryView StatusLast Update
0008493Multi Theft Auto : San AndreasGeneralpublic2014-08-26 13:01
ReporterMrTastyAssigned Tosbx320 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version1.4 
Target VersionFixed in Version1.4.1 
Summary0008493: JSON tables not reading longer numbers correctly
Description

Server: MTA:SA Server v1.4-release-6760
Client: Multi Theft Auto v1.4-release-6820

JSON does not correctly read numbers longer than 10 digits

Steps To Reproduce

fromJSON(toJSON({12345678900}))[1]
Command results: 2147483647 [number]

or

fromJSON("[ [ 12345678900 ] ]")[1]
Command results: 2147483647 [number]

Additional Information

Occurs on both server (r6760) and client (6820) MTA v1.4

TagsNo tags attached.

Activities

sbx320

2014-08-26 13:00

administrator   ~~0021867

Fixed in https://code.google.com/p/mtasa-blue/source/detail?r=6823.

Lua uses 64bit doubles internally anyway, thus we might as well read a double from JSON.

Note: fromJSON(toJSON({12345678900}))[1] will not return 12345678900 but the nearest representation due to rounding errors.

Issue History

Date Modified Username Field Change