]> granicus.if.org Git - php/commitdiff
Merge branch 'PHP-7.2' into PHP-7.3
authorStanislav Malyshev <stas@php.net>
Mon, 16 Dec 2019 08:38:54 +0000 (00:38 -0800)
committerStanislav Malyshev <stas@php.net>
Mon, 16 Dec 2019 08:38:54 +0000 (00:38 -0800)
* PHP-7.2:
  Fixed bug #78910
  Fix #78878: Buffer underflow in bc_shift_addsub
  Fix test
  Fix #78862: link() silently truncates after a null byte on Windows
  Fix #78863: DirectoryIterator class silently truncates after a null byte

1  2 
ext/exif/exif.c
ext/spl/spl_directory.c
ext/standard/link_win32.c

diff --cc ext/exif/exif.c
index 1c2f0d143bf5cf3617f03e290f99840994c101c6,c0be05922fbde95cd9cf62e1f44e2f497f8acafc..362e63d9a3286d43596a4a3cd1a2eca348b8c6c1
@@@ -3135,10 -3160,13 +3135,13 @@@ static int exif_process_IFD_in_MAKERNOT
  
                maker_note = maker_note_array+i;
  
 -              /*exif_error_docref(NULL EXIFERR_CC, ImageInfo, E_NOTICE, "check (%s,%s)", maker_note->make?maker_note->make:"", maker_note->model?maker_note->model:"");*/
 +              /*exif_error_docref(NULL EXIFERR_CC, ImageInfo, E_NOTICE, "check (%s)", maker_note->make?maker_note->make:"");*/
                if (maker_note->make && (!ImageInfo->make || strcmp(maker_note->make, ImageInfo->make)))
                        continue;
-               if (maker_note->id_string && strncmp(maker_note->id_string, value_ptr, maker_note->id_string_len))
+               if (maker_note->model && (!ImageInfo->model || strcmp(maker_note->model, ImageInfo->model)))
+                       continue;
+               if (maker_note->id_string && value_len >= maker_note->id_string_len
+                               && strncmp(maker_note->id_string, value_ptr, maker_note->id_string_len))
                        continue;
                break;
        }
Simple merge
Simple merge