about summary refs log tree commit diff
path: root/converter
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2020-06-07 18:21:35 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2020-06-07 18:21:35 +0000
commit3ff735500a9d428171deafe17d8c20a5d3087c0a (patch)
tree39956d329c41ed70c7db53249680cb055fd30c04 /converter
parent6c3e1408323a445c94f1840b5e541b51997b54e1 (diff)
downloadnetpbm-mirror-3ff735500a9d428171deafe17d8c20a5d3087c0a.tar.gz
netpbm-mirror-3ff735500a9d428171deafe17d8c20a5d3087c0a.tar.xz
netpbm-mirror-3ff735500a9d428171deafe17d8c20a5d3087c0a.zip
cleanup
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@3840 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter')
-rw-r--r--converter/ppm/ximtoppm.c23
1 files changed, 11 insertions, 12 deletions
diff --git a/converter/ppm/ximtoppm.c b/converter/ppm/ximtoppm.c
index eada0fb0..cb9f511d 100644
--- a/converter/ppm/ximtoppm.c
+++ b/converter/ppm/ximtoppm.c
@@ -22,6 +22,8 @@
 #include "shhopt.h"
 #include "nstring.h"
 
+
+
 struct CmdlineInfo {
     /* All the information the user supplied in the command line,
        in a form easy for the program to use.
@@ -113,8 +115,7 @@ ReadXimHeader(FILE *     const in_fp,
     header->ncolors = atoi(a_head.num_colors);
     header->nchannels = atoi(a_head.num_channels);
     header->bytes_per_line = atoi(a_head.bytes_per_line);
-/*    header->npics = atoi(a_head.num_pictures);
-*/
+/*    header->npics = atoi(a_head.num_pictures); */
     header->bits_channel = atoi(a_head.bits_per_channel);
     header->alpha_flag = atoi(a_head.alpha_channel);
     if (strlen(a_head.author)) {
@@ -321,19 +322,17 @@ ReadXimImage(FILE *     const in_fp,
 ***********************************************************************/
 
 static int
-ReadXim(in_fp, xim)
-    FILE *in_fp;
-    XimImage *xim;
-{
+ReadXim(FILE *     const in_fp,
+        XimImage * const xim) {
+
     if (!ReadXimHeader(in_fp, xim)) {
         pm_message("can't read xim header" );
-    return(0);
-    }
-    if (!ReadXimImage(in_fp, xim)) {
+        return 0;
+    } else if (!ReadXimImage(in_fp, xim)) {
         pm_message("can't read xim data" );
-    return(0);
-    }
-    return(1);
+        return 0;
+    } else
+        return 1;
 }