--- psiconv/trunk/lib/psiconv/generate_page.c 2004/01/06 20:15:01 184 +++ psiconv/trunk/lib/psiconv/generate_page.c 2004/02/25 20:57:10 231 @@ -1,6 +1,6 @@ /* generate_page.c - Part of psiconv, a PSION 5 file formats converter - Copyright (c) 2000 Frodo Looijaard + Copyright (c) 2000-2004 Frodo Looijaard This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -44,7 +44,7 @@ psiconv_progress(config,lev,0,"Writing page header"); if (!value) { - psiconv_error(config,0,psiconv_buffer_length(buf),"Null page header"); + psiconv_error(config,lev,0,"Null page header"); res = -PSICONV_E_GENERATE; goto ERROR1; } @@ -84,6 +84,10 @@ ERROR2: psiconv_free_paragraph_layout(basepara); ERROR1: + if (res) + psiconv_error(config,lev,0,"Writing of page header failed"); + else + psiconv_progress(config,lev,0,"End of page header"); return res; } @@ -97,7 +101,7 @@ psiconv_progress(config,lev,0,"Writing page layout section"); if (!value) { - psiconv_error(config,0,psiconv_buffer_length(buf),"Null page section"); + psiconv_error(config,lev,0,"Null page section"); res = -PSICONV_E_GENERATE; goto ERROR1; } @@ -138,5 +142,9 @@ ERROR2: psiconv_buffer_free(header_buf); ERROR1: + if (res) + psiconv_error(config,lev,0,"Writing of page layout section failed"); + else + psiconv_progress(config,lev,0,"End of page layout section"); return res; }