man bash

/escape character

voila

There are three quoting mechanisms: the escape character, single quotes,
and double quotes.

A non-quoted backslash (\) is the escape character.  It preserves the
literal value of the next character that follows, with the exception of
<newline>.  If a \<newline> pair appears, and the backslash is not itself
quoted, the \<newline> is treated as a line continuation (that is, it is
removed from the input stream and effectively ignored).



in other words, you want to escape the \ character with the escape
character, \

your command line would be

\\t\\x\\r

If you've got the source of te program handy, you might want to change the
\ character as a delimiter to something less confusing.


On Fri, 12 Apr 2002, Saurabh Shukla wrote:

>
> Hi...
>
> I have a C programme which takes parameters like "\t" or "\b" etc.. .
> I have to pass these params from the shell prompt.
>
> However when it give \t as a parameter, only the t reaches my program.
> if i pass \t\x\r , txr is passed to my programme.
>
> Is there some way i can get the actual parameter that is passed ? (ie with the 
>escpae characters )
>
> Thanks,
> saurabh
>
>

-- 
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://lists.slug.org.au/listinfo/slug

Reply via email to