diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2021-01-09 13:06:45 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2021-01-09 13:06:45 -0800 |
commit | cd8843c06ce2a37067edb5116f0c735ce3e3b7c7 (patch) | |
tree | 04baa507c5321dea5c96a1aafb4ce83bce43c915 /src/base/cmd/cmdHist.c | |
parent | bf96f0b31d255f56a355a92cb0fc2867eff68e9a (diff) | |
download | abc-cd8843c06ce2a37067edb5116f0c735ce3e3b7c7.tar.gz abc-cd8843c06ce2a37067edb5116f0c735ce3e3b7c7.tar.bz2 abc-cd8843c06ce2a37067edb5116f0c735ce3e3b7c7.zip |
Preventing command history from being overwritten by internal scripts.
Diffstat (limited to 'src/base/cmd/cmdHist.c')
-rw-r--r-- | src/base/cmd/cmdHist.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/base/cmd/cmdHist.c b/src/base/cmd/cmdHist.c index 218d832f..b8cfc98f 100644 --- a/src/base/cmd/cmdHist.c +++ b/src/base/cmd/cmdHist.c @@ -65,7 +65,8 @@ void Cmd_HistoryAddCommand( Abc_Frame_t * p, const char * command ) strncmp(Buffer,"time",4) && strncmp(Buffer,"quit",4) && strncmp(Buffer,"alias",5) && -// strncmp(Buffer,"source",6) && + strncmp(Buffer,"source abc.rc",13) && + strncmp(Buffer,"source ..\\abc.rc",16) && strncmp(Buffer,"history",7) && strncmp(Buffer,"hi ", 3) && strcmp(Buffer,"hi") && Buffer[strlen(Buffer)-1] != '?' ) { |