/[public]/psiconv/trunk/lib/psiconv/generate_page.c
ViewVC logotype

Diff of /psiconv/trunk/lib/psiconv/generate_page.c

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

Revision 230 Revision 231
42 psiconv_character_layout basechar; 42 psiconv_character_layout basechar;
43 43
44 psiconv_progress(config,lev,0,"Writing page header"); 44 psiconv_progress(config,lev,0,"Writing page header");
45 45
46 if (!value) { 46 if (!value) {
47 psiconv_error(config,0,psiconv_buffer_length(buf),"Null page header"); 47 psiconv_error(config,lev,0,"Null page header");
48 res = -PSICONV_E_GENERATE; 48 res = -PSICONV_E_GENERATE;
49 goto ERROR1; 49 goto ERROR1;
50 } 50 }
51 51
52 if (!(basepara=psiconv_basic_paragraph_layout())) { 52 if (!(basepara=psiconv_basic_paragraph_layout())) {
82ERROR3: 82ERROR3:
83 psiconv_free_character_layout(basechar); 83 psiconv_free_character_layout(basechar);
84ERROR2: 84ERROR2:
85 psiconv_free_paragraph_layout(basepara); 85 psiconv_free_paragraph_layout(basepara);
86ERROR1: 86ERROR1:
87 if (res)
88 psiconv_error(config,lev,0,"Writing of page header failed");
89 else
90 psiconv_progress(config,lev,0,"End of page header");
87 return res; 91 return res;
88} 92}
89 93
90int psiconv_write_page_layout_section(const psiconv_config config, 94int psiconv_write_page_layout_section(const psiconv_config config,
91 psiconv_buffer buf, int lev, 95 psiconv_buffer buf, int lev,
95 psiconv_buffer header_buf,footer_buf; 99 psiconv_buffer header_buf,footer_buf;
96 100
97 psiconv_progress(config,lev,0,"Writing page layout section"); 101 psiconv_progress(config,lev,0,"Writing page layout section");
98 102
99 if (!value) { 103 if (!value) {
100 psiconv_error(config,0,psiconv_buffer_length(buf),"Null page section"); 104 psiconv_error(config,lev,0,"Null page section");
101 res = -PSICONV_E_GENERATE; 105 res = -PSICONV_E_GENERATE;
102 goto ERROR1; 106 goto ERROR1;
103 } 107 }
104 108
105 if ((res = psiconv_write_u32(config,buf,lev+1,value->first_page_nr))) 109 if ((res = psiconv_write_u32(config,buf,lev+1,value->first_page_nr)))
136ERROR3: 140ERROR3:
137 psiconv_buffer_free(footer_buf); 141 psiconv_buffer_free(footer_buf);
138ERROR2: 142ERROR2:
139 psiconv_buffer_free(header_buf); 143 psiconv_buffer_free(header_buf);
140ERROR1: 144ERROR1:
145 if (res)
146 psiconv_error(config,lev,0,"Writing of page layout section failed");
147 else
148 psiconv_progress(config,lev,0,"End of page layout section");
141 return res; 149 return res;
142} 150}

Legend:
Removed from v.230  
changed lines
  Added in v.231

frodo@frodo.looijaard.name
ViewVC Help
Powered by ViewVC 1.1.26