2003-02-12 11:15 UTC+0300 Alexander Kresin <alex@belacy.belgorod.su>

This commit is contained in:
Alexander S.Kresin
2003-02-12 08:13:20 +00:00
parent f474e497fc
commit 588b775653
3 changed files with 20 additions and 4 deletions

View File

@@ -8,6 +8,11 @@
2002-12-01 23:12 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2003-02-12 11:15 UTC+0300 Alexander Kresin <alex@belacy.belgorod.su>
* source/rdd/dbcmd.c
* source/rdd/dbf1.c
! Bug fixed: APPEND FROM gave an error if the file <from> was opened already
2003-02-12 10:00 UTC+0300 Alexander Kresin <alex@belacy.belgorod.su>
+ source/codepage/cdpgedos.c
+ German dos codepage, provided by Guenther Steiner <byte-one@aon.at>

View File

@@ -3569,8 +3569,8 @@ static LPAREANODE GetTheOtherArea( char *szDriver, char * szFileName, BOOL creat
pInfo.abName = (BYTE *) szDbfName;
strcpy( ( char * ) pInfo.abName, szFileName );
pInfo.atomAlias = ( BYTE * ) "__TMPAREA";
pInfo.fShared = FALSE;
pInfo.fReadonly = FALSE;
pInfo.fShared = (createIt)? FALSE : !hb_set.HB_SET_EXCLUSIVE;
pInfo.fReadonly = (createIt)? FALSE : TRUE;
/* get the new area node */
pAreaNode = hb_rddNewAreaNode( pRDDNode, uiRddID );
@@ -3673,7 +3673,10 @@ static LPAREANODE GetTheOtherArea( char *szDriver, char * szFileName, BOOL creat
SELF_RELEASE( ( AREAP ) pAreaNode->pArea );
hb_xfree( pInfo.abName );
hb_xfree( pAreaNode );
hb_errRT_DBCMD( EG_OPEN, 0, NULL, "DBAPP" ); // Could not open it
if( createIt )
hb_errRT_DBCMD( EG_OPEN, 0, NULL, "DBAPP" ); // Could not open it
else
s_bNetError = TRUE; /* Temp fix! What about other types of errors? */
return NULL;
}
hb_xfree( szDbfName );
@@ -3756,7 +3759,11 @@ static ERRCODE rddMoveRecords( char *cAreaFrom, char *cAreaTo, PHB_ITEM pFields,
if ( cAreaFrom ) /*it's an APPEND FROM*/
{ /*make it current*/
pAreaRelease = s_pCurrArea = GetTheOtherArea( szDriver, cAreaFrom, FALSE, NULL );
pAreaRelease = GetTheOtherArea( szDriver, cAreaFrom, FALSE, NULL );
if( pAreaRelease )
s_pCurrArea = pAreaRelease;
else
return FAILURE;
pAreaFrom = (AREAP) pAreaRelease->pArea;
}
else

View File

@@ -1739,6 +1739,7 @@ ERRCODE hb_dbfOpen( DBFAREAP pArea, LPDBOPENINFO pOpenInfo )
if( ( ( PHB_DYNS ) pArea->atomAlias )->hArea )
{
hb_errRT_DBCMD( EG_DUPALIAS, EDBCMD_DUPALIAS, NULL, ( char * ) pOpenInfo->atomAlias );
hb_xfree( pArea->szDataFileName );
return FAILURE;
}
@@ -1793,7 +1794,10 @@ ERRCODE hb_dbfOpen( DBFAREAP pArea, LPDBOPENINFO pOpenInfo )
/* Exit if error */
if( pArea->hDataFile == FS_ERROR )
{
hb_xfree( pArea->szDataFileName );
return FAILURE;
}
/* Read file header and exit if error */
if( SELF_READDBHEADER( ( AREAP ) pArea ) == FAILURE )