Skip to content

rust: fix cron Sunday ranges and large-step overflow #962

Closed

Description

@athvin

Evidence

The parser folds day-of-week endpoint 7 to 0 before expanding a range, so 0-7 becomes Sunday only and 1-7 fails. The v += step loop can overflow for a parsed u32 step and panic or loop. Source.

Change

Expand a weekday range before normalizing Sunday and advance the step without overflow.

Done when

  • 0-7 and 1-7 select the documented weekdays.
  • */4294967295 and other large steps terminate safely.
  • Schedule creation and dispatcher parsing use the corrected behavior.

Activity

  1. added
    code-cleanup
    on Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    code-cleanup

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions