Commit a8f3d0b8 authored by Jeffrey Lee's avatar Jeffrey Lee
Browse files

Fix null pointer access

Detail:
  s/Fonts01 - hdr*_PixoPtr is optional, but SWIFont_CharBBox was loading from it without checking, causing random data to be read from zero page in some situations.
Admin:
  Tested on rev C2 BB.


Version 3.67. Tagged as 'Manager-3_67'
parent 4243fd3b
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "3.66"
Module_Version SETA 366
Module_MajorVersion SETS "3.67"
Module_Version SETA 367
Module_MinorVersion SETS ""
Module_Date SETS "02 Jan 2010"
Module_ApplicationDate SETS "02-Jan-10"
Module_Date SETS "24 Jul 2011"
Module_ApplicationDate SETS "24-Jul-11"
Module_ComponentName SETS "Manager"
Module_ComponentPath SETS "castle/RiscOS/Sources/Video/Render/Fonts/Manager"
Module_FullVersion SETS "3.66"
Module_HelpVersion SETS "3.66 (02 Jan 2010)"
Module_FullVersion SETS "3.67"
Module_HelpVersion SETS "3.67 (24 Jul 2011)"
END
/* (3.66)
/* (3.67)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 3.66
#define Module_MajorVersion_CMHG 3.67
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 02 Jan 2010
#define Module_Date_CMHG 24 Jul 2011
#define Module_MajorVersion "3.66"
#define Module_Version 366
#define Module_MajorVersion "3.67"
#define Module_Version 367
#define Module_MinorVersion ""
#define Module_Date "02 Jan 2010"
#define Module_Date "24 Jul 2011"
#define Module_ApplicationDate "02-Jan-10"
#define Module_ApplicationDate "24-Jul-11"
#define Module_ComponentName "Manager"
#define Module_ComponentPath "castle/RiscOS/Sources/Video/Render/Fonts/Manager"
#define Module_FullVersion "3.66"
#define Module_HelpVersion "3.66 (02 Jan 2010)"
#define Module_LibraryVersionInfo "3:66"
#define Module_FullVersion "3.67"
#define Module_HelpVersion "3.67 (24 Jul 2011)"
#define Module_LibraryVersionInfo "3:67"
......@@ -5246,10 +5246,11 @@ SWIFont_CharBBox PEntry Metrics, "R0,R5-R12"
TEQ R7,#hdr1_leafname
LDREQ R14,[R6,#hdr1_PixoPtr]
LDRNE R14,[R6,#hdr4_PixoPtr]
ADD R14,R14,#pixo_pointers
Debug bb2,"Charbbox: pixelsptrs, R0, R1 =",R14,R0,R1
LDR R14,[R14,R0,LSL #2]
TEQ R14,#0
ADDNE R14,R14,#pixo_pointers
Debug bb2,"Charbbox: pixelsptrs, R0, R1 =",R14,R0,R1
LDRNE R14,[R14,R0,LSL #2]
TEQNE R14,#0
BNE bbox_fromdisc ; use directly if already there
LDRB R0,[R6,#hdr_masterfont]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment