1
0
Fork 0
Commit graph

33 commits

Author SHA1 Message Date
Patryk Obara
a956f14de1 Inject newlines before displaying DOS prompt
In an earlier change, I removed appending newline outside of batch mode
in DOS shell code - that made DOSBox behave less like MS-DOS and more
like modern shells, that do not try to compensate for buggy
applications.

However, we should recognize that DOSBox (unlike e.g. FreeDOS) is designed
to run legacy applications, which might make assumptions about DOS
implementation. Some examples:

- PC Player Benchmark assumes, that help commands are displayed exactly
  at 80x25 terminal and formats the output to fill the whole screen
  (scrolling past DOS4GW messages).
- Quake and other ID games print shareware information on exit, but do
  it via a direct memory dump (not interrupts to print DOS text), and
  follow up with setting cursor exactly at line 22 (which is partly
  written already), expecting shell to inject newline.
- PCC Compiler prints status message on exit without newline, depending
  on MS-DOS shell behaviour.
- TEXTUTIL set of external commands do not print nothing to standard
  output, and are designed to clear the screen, therefore writing a
  newline after .COM commands would be a mistake.

Therefore we want to inject this newline, but not in every case.

New implementation reuses a static variable used by Program base class
(for purpose of translating UNIX newlines to DOS newlines) for detection
if it's appropriate to inject an additional newline or not.

Injecting the newline happens in function displaying the DOS prompt (so
we don't need to write additonal logic for separately handling batch
mode). When starting a non-COM, non-internal command the static variable
is set to the state indicating that next DOS prompt should inject the
newline.

Fixes: #208
2020-03-12 20:54:33 +01:00
Joshua Fern
f2029d71d8 Update copyright dates to 2020 2020-03-07 00:18:01 +01:00
Patryk Obara
5e41eaf150 Merge branch 'svn/trunk' r4333
Conflict resolutions required some algorithm adjustments.
2020-02-25 11:11:00 +01:00
Peter Veenstra
5d654fc5c5 Make value operator== const, add some limit checks in PrintConfigfile and related functions. Unify style a bit more.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@4332
2020-02-24 20:00:55 +00:00
krcroft
c9198b2944 Fix unsafe memory operations and warnings in the fatDrive class
- Move imageDiskList from pointer to vector of unique_ptr
- Replace string operations with size-limited versions
- Initialize members
- Eliminate unecessary casts
- Eliminate memory-leak on pointer assignment
2019-12-09 08:19:26 +01:00
Peter Veenstra
1fbaff47fc Update year and address of FSF
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@4183
2019-01-25 14:09:58 +00:00
Peter Veenstra
5bb10db88b Time keeps on ticking
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@4109
2018-05-29 12:58:58 +00:00
Peter Veenstra
6cf39c1fc6 Years update
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@4021
2017-05-30 11:35:08 +00:00
Peter Veenstra
0f4c92ca32 Year update.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3878
2015-01-06 14:40:32 +00:00
Peter Veenstra
2fea508f7f Year update
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3812
2013-01-15 09:03:13 +00:00
Peter Veenstra
6fc206193e Allow command /Cdir
Fix quoting so that command /c mount d "/tmp/a b" works
This breaks command /c "dir", but this doesn't work on real DOS either.
Let's hope everything still works.


Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3728
2011-06-24 21:02:05 +00:00
Peter Veenstra
999f33de27 Update year. Remove CVS tags
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3700
2011-04-26 09:34:55 +00:00
Ralf Grillenberger
143beec6b1 Add new features to the config command for control of the config file:
- manipulate the autoexec section
- display information on sections and values
- show the used config files and startup command line parameters 
- restart capability
- save config files either in the config or program directory

Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3651
2010-10-28 17:35:45 +00:00
Peter Veenstra
a78b2c4f8b Update year
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3548
2010-02-11 13:36:50 +00:00
Peter Veenstra
16d14b78e1 Some year and version numbers
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3410
2009-05-27 09:15:42 +00:00
Peter Veenstra
48edfe5409 Add Get_arglength, make trim(string a bit more flexible with whitespace so that configfiles from windows can be used on linux without converting
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3316
2009-03-11 20:18:37 +00:00
Peter Veenstra
e7d66020ea Add non-parsing WriteOut.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3184
2008-07-26 19:06:26 +00:00
Peter Veenstra
3f2e4fbd83 Allow longer commandlines in MOUNT and IMGMOUNT.
Fix crash reported by MiniMax (mount -u 0).
Fix bug reported by Tearex ("config -get" broken).
Add some protection that makes it harder to mount a directory from
within an executable.
Add some protection to make mounting from command /c much harder.
Add a securemode commandline switch to config and dosbox that should make it
impossible to mount a location when this isn't wanted by the user. (Addresses concerns of CVE-2007-6328)
Update documentation to reflect this.


Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3114
2008-03-02 11:13:47 +00:00
Peter Veenstra
61db3e5178 Move commandline to programs.h
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@3082
2008-01-19 11:02:29 +00:00
Peter Veenstra
fdd16dea1a Happy New Year\!
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2728
2007-01-08 19:45:42 +00:00
Peter Veenstra
132bbffb68 Add part of patch 1235377 of msharov and fix a few small bugs in the return values of the cpu cores
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2593
2006-04-11 19:02:33 +00:00
Peter Veenstra
df67775306 time passes on and on....
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2480
2006-02-09 11:47:57 +00:00
Peter Veenstra
593e664e8b Apply patch 1329540: Fixes compilation on GCC4.1 Changed order of definitions as well.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2349
2005-10-19 06:40:33 +00:00
Peter Veenstra
7f54c626ce New include system. Removed SHELL_AddAutoexec. New configuration base class + support functions
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2158
2005-03-25 11:43:36 +00:00
Peter Veenstra
2094d8b985 Year update
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2106
2005-02-10 10:21:12 +00:00
Peter Veenstra
ca409fd57c Typo in preamble
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@1899
2004-08-04 09:12:57 +00:00
Peter Veenstra
fcbd0fe854 Copyright to 2004
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@1552
2004-01-10 14:03:36 +00:00
Sjoerd van der Berg
7d6603d275 Delete the commandline and psp opbject in destructor.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@409
2002-10-25 10:48:08 +00:00
Sjoerd van der Berg
1591baeb42 Support for the new environment functions.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@343
2002-10-18 09:19:53 +00:00
Peter Veenstra
ed0e6bee75 moved MSG_Get from programs.h to dosbox.h. added AddMessage to dosbox.h
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@320
2002-10-16 18:41:12 +00:00
Sjoerd van der Berg
3df0c719f2 Changed Program Class, now supports the new command line class.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@308
2002-09-29 13:57:26 +00:00
Ulf Wohlers
bd35a40c9d new psp class used for all psp actions
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@264
2002-09-08 09:59:16 +00:00
Sjoerd van der Berg
42e5d0b779 First CVS upload.
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@80
2002-07-27 13:08:48 +00:00