/[MITgcm]/MITgcm/tools/mpack-1.6/part.c
ViewVC logotype

Diff of /MITgcm/tools/mpack-1.6/part.c

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1 by edhill, Tue Aug 26 20:45:25 2003 UTC revision 1.2 by jmc, Sat Feb 23 01:28:27 2008 UTC
# Line 27  Line 27 
27   */   */
28    
29  #include <stdio.h>  #include <stdio.h>
30    #include <stdlib.h>
31  #include <string.h>  #include <string.h>
32    
33  #include "part.h"  #include "part.h"
# Line 58  struct part *part_init(FILE *infile) Line 59  struct part *part_init(FILE *infile)
59  /*  /*
60   * Close and free 'part'.   * Close and free 'part'.
61   */   */
62  int part_close(struct part *part)  void part_close(struct part *part)
63  {  {
64      fclose(part->infile);      fclose(part->infile);
65      if (part->buf) free(part->buf);      if (part->buf) free(part->buf);
# Line 77  part_depth(struct part *part) Line 78  part_depth(struct part *part)
78  /*  /*
79   * Add to 'part' the multipart boundary 'boundary'.   * Add to 'part' the multipart boundary 'boundary'.
80   */   */
81  int  void part_addboundary(struct part *part, char *boundary)
 part_addboundary(struct part *part, char *boundary)  
82  {  {
83      /* Grow boundary array if necessary */      /* Grow boundary array if necessary */
84      if (part->boundary_num == part->boundary_alloc) {      if (part->boundary_num == part->boundary_alloc) {
# Line 165  part_gets(char *s, int n, struct part *p Line 165  part_gets(char *s, int n, struct part *p
165   * Leaves room in the input buffer to push back an additional single   * Leaves room in the input buffer to push back an additional single
166   * character using the prot_ungetc() macro.   * character using the prot_ungetc() macro.
167   */   */
168  int  void part_ungets(char *s, struct part *part)
 part_ungets(char *s, struct part *part)  
169  {  {
170      int len = strlen(s);      int len = strlen(s);
171      int i;      int i;

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.22