Project

General

Profile

Actions

Bug #6247

closed

Range not checked for day of year

Added by rubysubmit (Ruby Submit) over 12 years ago. Updated over 11 years ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 1.9.2p290
Backport:
[ruby-core:44088]

Description

File: strftime.c

case 'j': /* day of the year, 001 - 366 */
FMT('0', 3, "d", vtm->yday);
continue;

The range for the vtm->yday function is not checked as many of the other values are before formatting. The end result allows the day of year to be up to the size of a ushort.

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0