File: 60-id3lib-missing-nullpointer-check.patch

package info (click to toggle)
id3lib3.8.3 3.8.3-19
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,640 kB
  • sloc: cpp: 12,364; sh: 9,186; ansic: 7,240; makefile: 355; php: 325
file content (12 lines) | stat: -rw-r--r-- 273 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
This patch adds a check for a null pointer
--- a/src/header_tag.cpp
+++ b/src/header_tag.cpp
@@ -54,7 +54,7 @@
 {
   size_t bytesUsed = ID3_TagHeader::SIZE;
 
-  if (_info->is_extended)
+  if (_info && _info->is_extended)
   {
     bytesUsed += _info->extended_bytes;
   }