Mantis Bugtracker
  

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0007309 [Squeak] Collections minor always 03-08-09 16:44 04-18-10 22:05
Reporter lewis View Status public  
Assigned To lewis
Priority normal Resolution fixed  
Status closed   Product Version
Summary 0007309: IntegerArray>>at:put: needs range check in prim fallback code
Description Lack of range check in prim fallback code can lead to arithmetic overflow errors.

ia := IntegerArray new: 1.
whatToStore := -16r80000001.
ia at: 1 put: whatToStore.
result := ia at: 1.
result = whatToStore ==> false
result printStringHex ==> '7FFFFFFF'
Additional Information
Attached Files  IntegerArrayFallbackFix-dtl-M7309.3.cs [^] (1,457 bytes) 03-08-09 19:13
 IntegerArrayTest-dtl-M7309.cs [^] (2,943 bytes) 10-03-09 20:47

- Relationships
related to 0006987assigned lewis signed32BitValueOf:, signed64BitValueOf: etc. broken 

- Notes
(0013327 - 67 - 67 - 67 - 67 - 67 - 67)
lewis
10-03-09 20:48

Added unit tests IntegerArrayTest-dtl-M7309.cs to document the bug.
 
(0013328 - 46 - 46 - 46 - 46 - 46 - 46)
lewis
10-03-09 21:13

Tests and fix have been added to Squeak trunk.
 

- Issue History
Date Modified Username Field Change
03-08-09 16:44 lewis New Issue
03-08-09 16:44 lewis Issue Monitored: lewis
03-08-09 16:45 lewis Relationship added related to 0006987
03-08-09 16:50 lewis File Added: IntegerArrayFallbackFix-dtl-M7309.1.cs
03-08-09 19:13 lewis File Added: IntegerArrayFallbackFix-dtl-M7309.3.cs
03-08-09 19:14 lewis File Deleted: IntegerArrayFallbackFix-dtl-M7309.1.cs
10-03-09 20:47 lewis File Added: IntegerArrayTest-dtl-M7309.cs
10-03-09 20:48 lewis Note Added: 0013327
10-03-09 21:13 lewis Status new => resolved
10-03-09 21:13 lewis Resolution open => fixed
10-03-09 21:13 lewis Assigned To  => lewis
10-03-09 21:13 lewis Note Added: 0013328
04-18-10 22:05 andreas Status resolved => closed


Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
55 total queries executed.
34 unique queries executed.
Powered by Mantis Bugtracker