Skip to content

dune subst crashes on large files (32-bit systems) #9538

@emillon

Description

@emillon

dune subst crashes on 32-bit systems when a large file is present:

(true as of 3.12.1)

  Error: exception Invalid_argument("Bytes.create")
  Raised by primitive operation at Stdune__Io.Make.eagerly_input_string in file
    "otherlibs/stdune/src/io.ml", line 273, characters 14-30
  Called from Stdune__Io.Make.read_all.(fun) in file
    "otherlibs/stdune/src/io.ml", line 308, characters 16-40
  Called from Stdune__Exn.protectx in file "otherlibs/stdune/src/exn.ml", line
    10, characters 8-11
  Re-raised at Stdune__Exn.protectx in file "otherlibs/stdune/src/exn.ml", line
    16, characters 4-11
  Called from Dune__exe__Subst.subst_file in file "bin/subst.ml", line 113,
    characters 10-27
  Called from Stdlib__List.iter in file "list.ml", line 110, characters 12-15
  Called from Fiber__Core.O.(>>|).(fun) in file "vendor/fiber/src/core.ml",
    line 252, characters 36-41
  Called from Fiber__Scheduler.exec in file "vendor/fiber/src/scheduler.ml",
    line 76, characters 8-11
  Re-raised at Stdune__Exn.raise_with_backtrace in file
    "otherlibs/stdune/src/exn.ml", line 38, characters 27-56
  Called from Fiber__Scheduler.exec in file "vendor/fiber/src/scheduler.ml",
    line 76, characters 8-11

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions