1. 19 May, 2017 7 commits
    • Timothy B. Terriberry's avatar
      Minor documentation fix. · 0adf7303
      Timothy B. Terriberry authored
      Clarify that the value returned by op_current_link() is strictly
       less than the value returned by op_link_count() for seekable
    • Timothy B. Terriberry's avatar
      Harmonize op_raw_total() and op_raw_seek() · 37f83754
      Timothy B. Terriberry authored
      op_raw_seek() will fail if you try to seek to a byte position
       beyond the end of the file.
      However, the "end" is defined in terms of _of->end, which is
       specifically the end of the last Ogg page found in the underlying
       source (excluding any trailing non-Ogg data).
      op_raw_total(_of,-1) returns the total size of the stream by using
       _of->end, but it was also subtracting the offset of the first Opus
       page in the first link.
      Since there might have been other Ogg streams concurrently
       multiplexed with the first Opus stream whose BOS pages appear
       first, or there might simply be non-Ogg junk at the start, that
       left the caller with no way to determine the valid range of byte
       offsets that could be passed to op_raw_seek().
      Instead, make op_raw_total() pretend the first link starts at
       offset 0, and explicitly document that it's what defines the range
       of valid values to op_raw_seek().
      This is how our own seeking_example.c was using it, anyway.
    • Timothy B. Terriberry's avatar
      Improve handling of holes (corrupt pages). · fd65b94f
      Timothy B. Terriberry authored
      Previously, when we encountered a hole (a gap in the page sequence
       numbers), we would save off all of the packets from the first page
       after the hole, but not timestamp them.
      That meant when they were actually decoded, op_pcm_tell() would
       report a timestamp of 0 until reaching the last packet on that
      Instead, handle holes just like a raw seek.
      We reset the granule position tracking, and attempt to timestamp
       packets backwards from the end of the page.
      If the first page after the hole is an EOS page, we just throw it
       away (rather than risk playing invalid samples due to incorrect
      We also throw away the first 80 ms of audio after a hole, to allow
       the decoder state to reconverge.
      This patch also updates the example to report the hole and
       continue decoding, rather than immediately stopping when a hole is
       encountered, in order to test the above features.
    • Timothy B. Terriberry's avatar
      Avoid operations linear in the number of links. · f83675eb
      Timothy B. Terriberry authored
      Just in case some bozo makes a chained stream with 272,389 links
       with 16 samples in each (coded at 16 Mbps, including overheads).
      This avoids quadratic behavior for simple straight-through
       playback: we no longer do a linear search on each chain boundary
       or each call to op_pcm_tell().
      N seeks with M chains still requires O(N*log(M)) work.
    • Timothy B. Terriberry's avatar
      Minor comment updates. · 21ebba38
      Timothy B. Terriberry authored
      No code changes.
    • Timothy B. Terriberry's avatar
      Use OpenSSL's hostname validation if available. · cc1fff58
      Timothy B. Terriberry authored
      As of version 1.0.2, OpenSSL can finally do automatic hostname
       validation for us.
      Their implementation is likely to have received much better review
       than ours, and there are other good reasons to prefer it, so use it
       when we can.
    • Timothy B. Terriberry's avatar
      Fix two minor errors in hostname validation. · 0a94cf8f
      Timothy B. Terriberry authored
      RFC 6125 says that if the host is an IP address, a subjectAltName of
       type iPAddress must (no 2119 caps) be present and must be used.
      We would still fall back to checking the Common Name if no
       subjectAltName was present.
      https://marc.info/?l=openssl-dev&m=139617145216047&w=2 interprets
       RFC 6125 to say that if the host is a DNS name, but the certificate
       only contains a subjectAltName of type iPAddress, then we should
       still fall back to checking the Common Name.
      We would only check the Common Name if there was no subjectAltName
       of any type.
      Restructure the hostname validation to check IP addresses up-front
       and fall back to checking the Common Name in the proper cases.
  2. 10 Mar, 2017 1 commit
  3. 08 Feb, 2017 1 commit
  4. 08 Nov, 2016 1 commit
    • Ralph Giles's avatar
      mingw: Don't use deltarpm reconstruction. · 6a08376d
      Ralph Giles authored
      The fedora docker images ship without the necessary metadata
      to reconstruct rpm packages from installed data, so attempting
      to download delta rpm packages when updating the system just
      wastes time and bandwidth.
  5. 04 Nov, 2016 7 commits
  6. 28 Sep, 2016 1 commit
  7. 21 Sep, 2016 4 commits
  8. 16 Sep, 2016 1 commit
    • Timothy B. Terriberry's avatar
      Fix MSVC warnings. · d0c82543
      Timothy B. Terriberry authored
      Some of these pointed to real potential overflows (given arbitrary
       inputs by the calling application).
      I was sad about stripping const qualifiers from the struct addrinfo
       pointers, but MSVC seems to erroneously think that an array of
       pointers to constant data is itself a pointer to constant data (or
       maybe that it is not compatible with a const void *?), and
       converting the memmove()s to for loops triggered an erroneous
       warning about out-of-bounds array accesses in gcc (but on only one
       of the two identical loops).
  9. 29 Jul, 2016 4 commits
  10. 27 Jul, 2016 4 commits
  11. 08 Jul, 2016 2 commits
  12. 06 Jul, 2016 4 commits
  13. 04 Jul, 2016 3 commits