fix irksome bug with file import

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@1262 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Linas Vepstas 1998-10-04 08:13:35 +00:00
parent 1f60951ca5
commit 01eaa8db61
2 changed files with 13 additions and 4 deletions

View File

@ -169,9 +169,13 @@ static int writeDate( int fd, time_t secs );
/*******************************************************/ /*******************************************************/
int xaccGetFileIOError (void) int
xaccGetFileIOError (void)
{ {
return error_code; /* reset the error code */
int rc = error_code;
error_code = 0;
return rc;
} }
/*******************************************************/ /*******************************************************/

View File

@ -32,6 +32,7 @@
* also, check out a stock split tooo * also, check out a stock split tooo
*/ */
#include <errno.h>
#include <fcntl.h> #include <fcntl.h>
#include <string.h> #include <string.h>
#include <time.h> #include <time.h>
@ -55,9 +56,13 @@ static int error_code=0; /* error code, if error occurred */
/*******************************************************/ /*******************************************************/
int xaccGetQIFIOError (void) int
xaccGetQIFIOError (void)
{ {
return error_code; /* reset the error code */
int rc = error_code;
error_code = 0;
return rc;
} }
/********************************************************************\ /********************************************************************\