Skip to content
Commit 7095b7c4 authored by Sebastian Dröge's avatar Sebastian Dröge 🍵
Browse files

id3tag: Correctly validate the year from v1 tags before passing to GstDateTime

By using strtoul(), invalid values will get mapped to MAXULONG and we
would have to check errno. They won't get mapped to 0.

To solve this, use the signed g_ascii_strtoll(). This will map errors to
0 or G_MAXINT64 or G_MININT64, and the valid range for GstDateTime is >
0 and <= 9999 so we can directly check for this here.

Fixes gstreamer#384
parent e8450397
Loading
Loading
Loading
Pipeline #33355 passed with stages
in 1 hour, 11 minutes, and 5 seconds
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment