Fixed crash with temp on linux and mac
parent
05a89b37e8
commit
9d54e76590
|
@ -514,6 +514,9 @@ Sys_Font_Path(name, parameters){
|
|||
}
|
||||
}
|
||||
|
||||
Partition *part = &shared_vars.font_scratch;
|
||||
path.temp = begin_temp_memory(part);
|
||||
|
||||
b32 got_font = false;
|
||||
if (pattern_styled != 0){
|
||||
if (FcConfigSubstitute(fc_config, pattern_styled, FcMatchPattern)){
|
||||
|
@ -526,8 +529,6 @@ Sys_Font_Path(name, parameters){
|
|||
if (font != 0){
|
||||
FcPatternGetString(font, FC_FILE, 0, &filename);
|
||||
if (filename != 0){
|
||||
Partition *part = &shared_vars.font_scratch;
|
||||
path.temp = begin_temp_memory(part);
|
||||
i32 len = str_size((char*)filename);
|
||||
char *buffer = push_array(part, char, len + 1);
|
||||
if (buffer == 0){
|
||||
|
@ -563,8 +564,6 @@ Sys_Font_Path(name, parameters){
|
|||
if (font != 0){
|
||||
FcPatternGetString(font, FC_FILE, 0, &filename);
|
||||
if (filename != 0){
|
||||
Partition *part = &shared_vars.font_scratch;
|
||||
path.temp = begin_temp_memory(part);
|
||||
i32 len = str_size((char*)filename);
|
||||
char *buffer = push_array(part, char, len + 1);
|
||||
if (buffer == 0){
|
||||
|
|
|
@ -348,10 +348,10 @@ Sys_Font_Path(name, parameters){
|
|||
OSX_Font_Match match = osx_get_font_match(name, pt_size, italic, bold);
|
||||
|
||||
Font_Path path = {0};
|
||||
if (match.path != 0){
|
||||
Partition *part = &shared_vars.font_scratch;
|
||||
path.temp = begin_temp_memory(part);
|
||||
Partition *part = &shared_vars.font_scratch;
|
||||
path.temp = begin_temp_memory(part);
|
||||
|
||||
if (match.path != 0){
|
||||
i32 len = str_size(match.path);
|
||||
char *buffer = push_array(part, char, len + 1);
|
||||
if (buffer == 0){
|
||||
|
|
Loading…
Reference in New Issue