fix tiny bug when >> is used on a non-existing file
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2214
This commit is contained in:
parent
df1b64ffad
commit
3c88eaf92d
1 changed files with 5 additions and 2 deletions
|
@ -16,7 +16,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
/* $Id: shell.cpp,v 1.60 2005-04-29 14:10:45 qbix79 Exp $ */
|
||||
/* $Id: shell.cpp,v 1.61 2005-05-31 20:19:13 qbix79 Exp $ */
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdarg.h>
|
||||
|
@ -195,8 +195,11 @@ void DOS_Shell::ParseLine(char * line) {
|
|||
bool status = true;
|
||||
/* Create if not exist. Open if exist. Both in read/write mode */
|
||||
if(append) {
|
||||
if( (status = DOS_OpenFile(out,2,&dummy)) )
|
||||
if( (status = DOS_OpenFile(out,2,&dummy)) ) {
|
||||
DOS_SeekFile(1,&bigdummy,DOS_SEEK_END);
|
||||
} else {
|
||||
status = DOS_CreateFile(out,2,&dummy); //Create if not exists.
|
||||
}
|
||||
}
|
||||
else
|
||||
status = DOS_OpenFileExtended(out,2,2,0x12,&dummy,&dummy2);
|
||||
|
|
Loading…
Add table
Reference in a new issue