Commit eabc8d72e0dddf8fa85ba07677ba4ba565283e1e

Alexei Podtelezhnikov 2015-04-12T23:16:48

[psaux,psnames,type1,type42] NULL.

diff --git a/src/psaux/afmparse.c b/src/psaux/afmparse.c
index 0a86853..3ad44ec 100644
--- a/src/psaux/afmparse.c
+++ b/src/psaux/afmparse.c
@@ -446,7 +446,7 @@
                        FT_Offset*  len )
   {
     AFM_Stream  stream = parser->stream;
-    char*       key    = 0;  /* make stupid compiler happy */
+    char*       key    = NULL;  /* make stupid compiler happy */
 
 
     if ( line )
diff --git a/src/psaux/psobjs.c b/src/psaux/psobjs.c
index a0c0e09..c7cbc67 100644
--- a/src/psaux/psobjs.c
+++ b/src/psaux/psobjs.c
@@ -81,7 +81,7 @@
     table->max_elems = count;
     table->init      = 0xDEADBEEFUL;
     table->num_elems = 0;
-    table->block     = 0;
+    table->block     = NULL;
     table->capacity  = 0;
     table->cursor    = 0;
 
@@ -619,8 +619,8 @@
 
 
     token->type  = T1_TOKEN_TYPE_NONE;
-    token->start = 0;
-    token->limit = 0;
+    token->start = NULL;
+    token->limit = NULL;
 
     /* first of all, skip leading whitespace */
     ps_parser_skip_spaces( parser );
@@ -701,7 +701,7 @@
 
     if ( !token->limit )
     {
-      token->start = 0;
+      token->start = NULL;
       token->type  = T1_TOKEN_TYPE_NONE;
     }
 
@@ -1547,7 +1547,7 @@
       FT_GlyphLoader_Rewind( loader );
 
       builder->hints_globals = size->internal;
-      builder->hints_funcs   = 0;
+      builder->hints_funcs   = NULL;
 
       if ( hinting )
         builder->hints_funcs = glyph->internal->glyph_hints;
diff --git a/src/psaux/t1decode.c b/src/psaux/t1decode.c
index 4386119..2e19928 100644
--- a/src/psaux/t1decode.c
+++ b/src/psaux/t1decode.c
@@ -1581,7 +1581,7 @@
 
     /* retrieve PSNames interface from list of current modules */
     {
-      FT_Service_PsCMaps  psnames = 0;
+      FT_Service_PsCMaps  psnames;
 
 
       FT_FACE_FIND_GLOBAL_SERVICE( face, psnames, POSTSCRIPT_CMAPS );
diff --git a/src/psnames/psmodule.c b/src/psnames/psmodule.c
index 448be1e..0f04c2f 100644
--- a/src/psnames/psmodule.c
+++ b/src/psnames/psmodule.c
@@ -312,7 +312,7 @@
 
     /* we first allocate the table */
     table->num_maps = 0;
-    table->maps     = 0;
+    table->maps     = NULL;
 
     if ( !FT_NEW_ARRAY( table->maps, num_glyphs + EXTRA_GLYPH_LIST_SIZE ) )
     {
diff --git a/src/type1/t1gload.c b/src/type1/t1gload.c
index 4af8d71..829e874 100644
--- a/src/type1/t1gload.c
+++ b/src/type1/t1gload.c
@@ -504,7 +504,7 @@
 
       /* Set the control data to null - it is no longer available if   */
       /* loaded incrementally.                                         */
-      t1glyph->control_data = 0;
+      t1glyph->control_data = NULL;
       t1glyph->control_len  = 0;
     }
 #endif
diff --git a/src/type1/t1load.c b/src/type1/t1load.c
index 39acef2..376c90c 100644
--- a/src/type1/t1load.c
+++ b/src/type1/t1load.c
@@ -2213,8 +2213,8 @@
     /* the `lengths' field must be released later             */
     type1->glyph_names_block    = loader.glyph_names.block;
     type1->glyph_names          = (FT_String**)loader.glyph_names.elements;
-    loader.glyph_names.block    = 0;
-    loader.glyph_names.elements = 0;
+    loader.glyph_names.block    = NULL;
+    loader.glyph_names.elements = NULL;
 
     /* we must now build type1.encoding when we have a custom array */
     if ( type1->encoding_type == T1_ENCODING_TYPE_ARRAY )
diff --git a/src/type1/t1objs.c b/src/type1/t1objs.c
index 74fb4fa..af89888 100644
--- a/src/type1/t1objs.c
+++ b/src/type1/t1objs.c
@@ -86,7 +86,7 @@
       if ( funcs )
         funcs->destroy( (PSH_Globals)size->root.internal );
 
-      size->root.internal = 0;
+      size->root.internal = NULL;
     }
   }
 
@@ -144,7 +144,7 @@
   FT_LOCAL_DEF( void )
   T1_GlyphSlot_Done( FT_GlyphSlot  slot )
   {
-    slot->internal->glyph_hints = 0;
+    slot->internal->glyph_hints = NULL;
   }
 
 
@@ -224,7 +224,7 @@
     }
 
     T1_Done_Blend( face );
-    face->blend = 0;
+    face->blend = NULL;
 #endif
 
     /* release font info strings */
@@ -457,7 +457,7 @@
 
       /* no embedded bitmap support */
       root->num_fixed_sizes = 0;
-      root->available_sizes = 0;
+      root->available_sizes = NULL;
 
       root->bbox.xMin =   type1->font_bbox.xMin            >> 16;
       root->bbox.yMin =   type1->font_bbox.yMin            >> 16;
diff --git a/src/type1/t1parse.c b/src/type1/t1parse.c
index feea224..c73b2b2 100644
--- a/src/type1/t1parse.c
+++ b/src/type1/t1parse.c
@@ -143,13 +143,13 @@
     FT_ULong   size;
 
 
-    psaux->ps_parser_funcs->init( &parser->root, 0, 0, memory );
+    psaux->ps_parser_funcs->init( &parser->root, NULL, NULL, memory );
 
     parser->stream       = stream;
     parser->base_len     = 0;
-    parser->base_dict    = 0;
+    parser->base_dict    = NULL;
     parser->private_len  = 0;
-    parser->private_dict = 0;
+    parser->private_dict = NULL;
     parser->in_pfb       = 0;
     parser->in_memory    = 0;
     parser->single_block = 0;
@@ -445,7 +445,7 @@
         parser->single_block = 1;
         parser->private_dict = parser->base_dict;
         parser->private_len  = size;
-        parser->base_dict    = 0;
+        parser->base_dict    = NULL;
         parser->base_len     = 0;
       }
 
diff --git a/src/type42/t42objs.c b/src/type42/t42objs.c
index d0a05d6..2756adf 100644
--- a/src/type42/t42objs.c
+++ b/src/type42/t42objs.c
@@ -92,8 +92,8 @@
     /* the `lengths' field must be released later             */
     type1->glyph_names_block    = loader.glyph_names.block;
     type1->glyph_names          = (FT_String**)loader.glyph_names.elements;
-    loader.glyph_names.block    = 0;
-    loader.glyph_names.elements = 0;
+    loader.glyph_names.block    = NULL;
+    loader.glyph_names.elements = NULL;
 
     /* we must now build type1.encoding when we have a custom array */
     if ( type1->encoding_type == T1_ENCODING_TYPE_ARRAY )
@@ -285,7 +285,7 @@
 
     /* no embedded bitmap support */
     root->num_fixed_sizes = 0;
-    root->available_sizes = 0;
+    root->available_sizes = NULL;
 
     /* Load the TTF font embedded in the T42 font */
     {
@@ -461,8 +461,8 @@
     FT_FREE( face->unicode_map.maps );
     face->unicode_map.num_maps = 0;
 
-    face->root.family_name = 0;
-    face->root.style_name  = 0;
+    face->root.family_name = NULL;
+    face->root.style_name  = NULL;
   }
 
 
@@ -632,10 +632,10 @@
     slot->bitmap_left   = 0;
     slot->bitmap_top    = 0;
     slot->num_subglyphs = 0;
-    slot->subglyphs     = 0;
-    slot->control_data  = 0;
+    slot->subglyphs     = NULL;
+    slot->control_data  = NULL;
     slot->control_len   = 0;
-    slot->other         = 0;
+    slot->other         = NULL;
     slot->format        = FT_GLYPH_FORMAT_NONE;
 
     slot->linearHoriAdvance = 0;
diff --git a/src/type42/t42parse.c b/src/type42/t42parse.c
index d046408..109e996 100644
--- a/src/type42/t42parse.c
+++ b/src/type42/t42parse.c
@@ -142,11 +142,11 @@
     FT_Long   size;
 
 
-    psaux->ps_parser_funcs->init( &parser->root, 0, 0, memory );
+    psaux->ps_parser_funcs->init( &parser->root, NULL, NULL, memory );
 
     parser->stream    = stream;
     parser->base_len  = 0;
-    parser->base_dict = 0;
+    parser->base_dict = NULL;
     parser->in_memory = 0;
 
     /*******************************************************************/