More code formatting.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124
diff --git a/builds/mac/ftmac.c b/builds/mac/ftmac.c
index 4691ded..cbb3cd7 100644
--- a/builds/mac/ftmac.c
+++ b/builds/mac/ftmac.c
@@ -940,7 +940,7 @@ typedef short ResourceIndex;
{
err = lookup_lwfn_by_fond( pathname, lwfn_file_name,
buff, sizeof ( buff ) );
- if ( FT_Err_Ok == err )
+ if ( !err )
have_lwfn = 1;
}
@@ -1217,7 +1217,7 @@ typedef short ResourceIndex;
}
CloseResFile( res_ref );
- if ( FT_Err_Ok == error && NULL != aface )
+ if ( !error && aface )
(*aface)->num_faces = num_faces_in_res;
return error;
}
@@ -1279,7 +1279,7 @@ typedef short ResourceIndex;
error = lookup_lwfn_by_fond( path_fond, lwfn_file_name,
path_lwfn, sizeof ( path_lwfn ) );
- if ( FT_Err_Ok == error )
+ if ( !error )
have_lwfn = 1;
}
@@ -1315,7 +1315,7 @@ typedef short ResourceIndex;
error = lookup_lwfn_by_fond( path_fond, lwfn_file_name,
path_lwfn, sizeof ( path_lwfn ) );
- if ( FT_Err_Ok == error )
+ if ( !error )
have_lwfn = 1;
}
@@ -1332,7 +1332,7 @@ typedef short ResourceIndex;
error = FT_ERR( Unknown_File_Format );
found_no_lwfn_file:
- if ( have_sfnt && FT_Err_Ok != error )
+ if ( have_sfnt && error )
error = FT_New_Face_From_SFNT( library,
sfnt_id,
face_index,
@@ -1363,7 +1363,7 @@ typedef short ResourceIndex;
/* if it works, fine. */
error = FT_New_Face_From_Suitcase( library, pathname, face_index, aface );
- if ( error == 0 )
+ if ( !error )
return error;
/* let it fall through to normal loader (.ttf, .otf, etc.); */
@@ -1403,7 +1403,7 @@ typedef short ResourceIndex;
/* try resourcefork based font: LWFN, FFIL */
error = FT_New_Face_From_Resource( library, (UInt8 *)pathname,
face_index, aface );
- if ( error != 0 || *aface != NULL )
+ if ( error || *aface )
return error;
/* let it fall through to normal loader (.ttf, .otf, etc.) */
@@ -1458,7 +1458,7 @@ typedef short ResourceIndex;
error = FT_ERR( Cannot_Open_Resource );
error = FT_New_Face_From_Resource( library, pathname, face_index, aface );
- if ( error != 0 || *aface != NULL )
+ if ( error || *aface )
return error;
/* fallback to datafork font */
@@ -1515,7 +1515,7 @@ typedef short ResourceIndex;
error = FT_ERR( Cannot_Open_Resource );
error = FT_New_Face_From_Resource( library, pathname, face_index, aface );
- if ( error != 0 || *aface != NULL )
+ if ( error || *aface )
return error;
/* fallback to datafork font */
diff --git a/src/base/ftmac.c b/src/base/ftmac.c
index e93d7e8..55cdea6 100644
--- a/src/base/ftmac.c
+++ b/src/base/ftmac.c
@@ -1029,7 +1029,7 @@
error = FT_THROW( Cannot_Open_Resource );
error = FT_New_Face_From_Resource( library, pathname, face_index, aface );
- if ( error != 0 || *aface != NULL )
+ if ( error || *aface )
return error;
/* fallback to datafork font */
diff --git a/src/cff/cffparse.c b/src/cff/cffparse.c
index 9b5ad72..a848631 100644
--- a/src/cff/cffparse.c
+++ b/src/cff/cffparse.c
@@ -902,7 +902,7 @@
priv->vsindex,
subFont->lenNDV,
subFont->NDV );
- if ( error != FT_Err_Ok )
+ if ( error )
goto Exit;
}
diff --git a/src/type1/t1load.c b/src/type1/t1load.c
index 2b64f85..03b0879 100644
--- a/src/type1/t1load.c
+++ b/src/type1/t1load.c
@@ -2156,7 +2156,7 @@
parser->root.error = t1_load_keyword( face,
loader,
keyword );
- if ( parser->root.error != FT_Err_Ok )
+ if ( parser->root.error )
{
if ( FT_ERR_EQ( parser->root.error, Ignore ) )
parser->root.error = FT_Err_Ok;