… | |
… | |
159 | return 0; |
159 | return 0; |
160 | |
160 | |
161 | ERROR2: |
161 | ERROR2: |
162 | free (*result); |
162 | free (*result); |
163 | ERROR1: |
163 | ERROR1: |
164 | psiconv_warn(config,lev+1,off,"Reading of Word Status Section failed"); |
164 | psiconv_error(config,lev+1,off,"Reading of Word Status Section failed"); |
165 | if (length) |
165 | if (length) |
166 | *length = 0; |
166 | *length = 0; |
167 | if (!res) |
167 | if (!res) |
168 | return -PSICONV_E_NOMEM; |
168 | return -PSICONV_E_NOMEM; |
169 | else |
169 | else |
… | |
… | |
375 | ERROR6: |
375 | ERROR6: |
376 | free(style->name); |
376 | free(style->name); |
377 | ERROR5: |
377 | ERROR5: |
378 | for (j = 0; j < i ;j++) { |
378 | for (j = 0; j < i ;j++) { |
379 | if (!(style = psiconv_list_get((*result)->styles,j))) { |
379 | if (!(style = psiconv_list_get((*result)->styles,j))) { |
380 | psiconv_warn(config,lev+1,off,"Massive memory corruption"); |
380 | psiconv_error(config,lev+1,off,"Massive memory corruption"); |
381 | goto ERROR4; |
381 | goto ERROR4; |
382 | } |
382 | } |
383 | psiconv_free_character_layout(style->character); |
383 | psiconv_free_character_layout(style->character); |
384 | psiconv_free_paragraph_layout(style->paragraph); |
384 | psiconv_free_paragraph_layout(style->paragraph); |
385 | free(style->name); |
385 | free(style->name); |
… | |
… | |
389 | ERROR3: |
389 | ERROR3: |
390 | psiconv_free_word_style((*result)->normal); |
390 | psiconv_free_word_style((*result)->normal); |
391 | ERROR2: |
391 | ERROR2: |
392 | free (*result); |
392 | free (*result); |
393 | ERROR1: |
393 | ERROR1: |
394 | psiconv_warn(config,lev+1,off,"Reading of Word Status Section failed"); |
394 | psiconv_error(config,lev+1,off,"Reading of Word Status Section failed"); |
395 | if (length) |
395 | if (length) |
396 | *length = 0; |
396 | *length = 0; |
397 | if (!res) |
397 | if (!res) |
398 | return -PSICONV_E_NOMEM; |
398 | return -PSICONV_E_NOMEM; |
399 | else |
399 | else |