Skip to content

Commit ed3329f

Browse files
authored
Merge pull request ocaml#12742 from jmid/fix-domain-assertion
Fix assertion failure from ocaml#12712
2 parents fc57b23 + 624b9e7 commit ed3329f

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Changes

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -475,6 +475,9 @@ Working version
475475

476476
### Bug fixes:
477477

478+
- #12712, #12742: fix an assertion boundary case in `caml_reset_young_limit`
479+
(Jan Midtgaard, review by Guillaume Munch-Maccagnoni)
480+
478481
- #10652, #12720: fix evaluation order in presence of optional arguments
479482
(Jacques Garrigue, report by Leo White, review by Vincent Laviron)
480483

runtime/domain.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1618,7 +1618,7 @@ void caml_interrupt_all_signal_safe(void)
16181618
races. */
16191619
void caml_reset_young_limit(caml_domain_state * dom_st)
16201620
{
1621-
CAMLassert ((uintnat)dom_st->young_ptr > (uintnat)dom_st->young_trigger);
1621+
CAMLassert ((uintnat)dom_st->young_ptr >= (uintnat)dom_st->young_trigger);
16221622
/* An interrupt might have been queued in the meanwhile; the
16231623
atomic_exchange achieves the proper synchronisation with the
16241624
reads that follow (an atomic_store is not enough). */

0 commit comments

Comments
 (0)