dash built-in echo expands \nnn sequences
Asked by
Mauricio Villegas
Binary package hint: dash
dash 0.5.5.1-7.2ubuntu1
Ubuntu 11.04
Linux eclipse 2.6.38-10-generic #46-Ubuntu SMP Tue Jun 28 15:07:17 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
When running the following I get:
$ dash -c "echo 'hello\7there'"
hellothere
Apparently the '\7' gets expanded to ascii character 7 (bell). In other shells this does not happen:
$ bash -c "echo 'hello\7there'"
hello\7there
$ ksh -c "echo 'hello\7there'"
hello\7there
$ zsh -c "echo 'hello\7there'"
hello\7there
Is this supposed to be the correct behavior or is it a bug?
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Ubuntu dash Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Mauricio Villegas
- Solved:
- Last query:
- Last reply:
To post a message you must log in.