Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 6175cfbe1acb344064ec50dd1253c005f0a5322bcb6a10679a3f89dd2889a93c
Ticket: c9663296fd31fbb2fa1ff1cf019b59f432983516
GrowStringBuffer and GrowUnicodeBuffer do not check for overflows
User & Date: apnadkarni on 2023-04-23 02:49:00
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/x-markdown"
  4. comment changed to:
    On reallocations, `GrowStringBuffer` doubles the requested size without checking for integer overflow. This applies to 8.7 and 9.0 (may be even earlier).
    
    On the second attempt, it limits the size to `INT_MAX` which is no longer the limit in 64-bit 9.0 (should be TCL_SIZE_MAX).
    
    Just noting for now for future correction. The doubling every time also has to be reconsidered as it wastes a lot of memory once sizes get large (bigdata tests) causing memory exhaustion panics when there should not be.
    
  5. is_private changed to: "0"
  6. login: "apnadkarni"
  7. priority changed to: "5 Medium"
  8. private_contact changed to: "9546e9877f1a8899e25a89082561ee694e7fb402"
  9. resolution changed to: "None"
  10. severity changed to: "Minor"
  11. status changed to: "Open"
  12. submitter changed to: "apnadkarni"
  13. subsystem changed to: "41. Memory Allocation"
  14. title changed to: "GrowStringBuffer does not check for overflows"
  15. type changed to: "Bug"