aboutsummaryrefslogtreecommitdiff
Patch contents copied from Mozilla esr45 changeset 312077:7ebfe49f001c

  changeset:   312077:7ebfe49f001c
  user:        Randell Jesup <rjesup@jesup.org>
  Date:        Fri Apr 15 23:11:01 2016 -0400
  summary:     Bug 1263384: validate input frames against configured resolution in vp8 r=rillian, a=ritu,lizzard

  MozReview-Commit-ID: BxDCnJe0mzs

--- libvpx-1.5.0/vp8/vp8_cx_iface.c.orig	2015-11-09 17:12:38.000000000 -0500
+++ libvpx-1.5.0/vp8/vp8_cx_iface.c	2016-06-08 08:48:46.037213092 -0400
@@ -860,11 +860,20 @@
     if (img != NULL) {
       res = image2yuvconfig(img, &sd);
 
-      if (vp8_receive_raw_frame(ctx->cpi, ctx->next_frame_flag | lib_flags, &sd,
-                                dst_time_stamp, dst_end_time_stamp)) {
-        VP8_COMP *cpi = (VP8_COMP *)ctx->cpi;
-        res = update_error_state(ctx, &cpi->common.error);
-      }
+            if (sd.y_width != ctx->cfg.g_w || sd.y_height != ctx->cfg.g_h) {
+                /* from vp8_encoder.h for g_w/g_h:
+                   "Note that the frames passed as input to the encoder must have this resolution"
+                */
+                ctx->base.err_detail = "Invalid input frame resolution";
+                res = VPX_CODEC_INVALID_PARAM;
+            } else {
+                if (vp8_receive_raw_frame(ctx->cpi, ctx->next_frame_flag | lib_flags,
+                                          &sd, dst_time_stamp, dst_end_time_stamp))
+                {
+                    VP8_COMP *cpi = (VP8_COMP *)ctx->cpi;
+                    res = update_error_state(ctx, &cpi->common.error);
+                }
+            }
 
       /* reset for next frame */
       ctx->next_frame_flag = 0;
2.2. Marius Bakke 2019-12-01gnu: swig.scm: Sort module inputs alphabetically....* gnu/packages/swig.scm: Sort module inputs alphabetically. Efraim Flashner 2019-12-01gnu: swig: Clean up inputs....* gnu/packages/swig.scm (swig)[inputs]: Move perl, guile-2.0 ... [inputs]: ... to here. Efraim Flashner 2019-11-15gnu: swig: Fix cross-compilation....* gnu/packages/swig.scm (swig)[inputs]: Add pcre that is needed when cross-compiling. Mathieu Othacehe 2019-02-09gnu: swig: Fix FTBFS with GCC >= 6....* gnu/packages/swig.scm (swig)[arguments]: Add phase to remove -isystem flag to GCC. Marius Bakke 2018-10-18gnu: swig: Fix build on i686....* gnu/packages/patches/swig-guile-gc.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/swig.scm (swig)[source](patches): Use it. Marius Bakke 2018-05-30Revert "gnu: swig: Patch for Octave 4.4."...This reverts commit 3771000f893d4b53e302f5bca07afeba69e76cd4. Mark H Weaver 2018-05-29gnu: swig: Patch for Octave 4.4....* gnu/packages/swig.scm (swig)[source]: Add patch. * gnu/packages/patches/swig-octave-patches.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. Kei Kebreau