Dennis Williamson writes:
> On Tue, Sep 1, 2015 at 4:24 PM, Andreas Schwab
> wrote:
>
>> Dennis Williamson writes:
>>
>> > $ echo $((foo)) # expansion succeeds, indirection fails
>> > dash: 4: Illegal number: bar
>>
>> The indirection didn't fail, it just didn't produce a number, so the
>> exp
On 9/1/15 6:46 PM, Helmut Karlowski wrote:
> Do you refer to the table titled "Circumflex Control Characters in stty"?
>
> It states for example:
>
> ?
Yeah, that's a problem. I've fixed that.
>
> Running:
>
> echo $'\c?' |od -a
> echo $'\c[\c\\c]\c^\c_\c?' |od -a
>
> bash prints:
>
>
On 9/1/15 4:13 PM, Dennis Williamson wrote:
> The version of dash I have handy (0.5.7) has math support which IMHO is
> broken:
>
> $ foo=bar
> $ bar=5
> $ echo $foo
> bar
> $ echo $((foo))
> dash: 4: Illegal number: bar
> $ echo $(($foo))
> 5
> $ echo $((bar))
> 5
> $ echo $(($bar))
> 5
Dash
On 9/1/15 12:50 AM, Clint Hepner wrote:
> Bash Version: 4.3
> Patch Level: 42
> Release Status: release
>
> Description:
>
> Parameter names are recursively evaluated in an arithmetic expression, but
> this
> is not done consistently.
Parameter names are expanded and treated as expressions whe
On 9/1/15 5:05 PM, Dennis Williamson wrote:
> It's the line above those two where I demonstrate the failure in the
> indirection and equivalency.
>
> $ echo $((foo)) # expansion succeeds, indirection fails
> dash: 4: Illegal number: bar
Because `foo' is expanded, but the value is not treated as
On Wed, Sep 2, 2015 at 2:16 AM, Andreas Schwab
wrote:
> Dennis Williamson writes:
>
> > I disagree. The _expansion_ produced "bar"
>
> That's not an expansion. Only $ introduces an expansion.
>
> Andreas.
>
>
The $ is implied.
--
Visit serverfault.com to get your system administration questio
On Wed, Sep 02, 2015 at 10:16:14AM -0500, Dennis Williamson wrote:
> The $ is implied.
That is completely absurd. (And wrong.)
bash-4.3$ echo $'\?'
?
\? should be added there.
On 9/2/15 11:19 AM, Greg Wooledge wrote:
> On Wed, Sep 02, 2015 at 10:16:14AM -0500, Dennis Williamson wrote:
>> The $ is implied.
>
> That is completely absurd. (And wrong.)
Not exactly. When the arithmetic evaluator encounters a token that is of
the form of a shell identifier (`bar'), in a co
On 9/2/15 10:00 AM, ziyunfei wrote:
> bash-4.3$ echo $'\?'
> ?
>
> \? should be added there.
Backslash-escape sequences that are not present in the documentation are
left unchanged. Posix leaves these up to the implementation.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
On Wed, Sep 02, 2015 at 11:24:42AM -0400, Chet Ramey wrote:
> On 9/2/15 11:19 AM, Greg Wooledge wrote:
> > On Wed, Sep 02, 2015 at 10:16:14AM -0500, Dennis Williamson wrote:
> >> The $ is implied.
> >
> > That is completely absurd. (And wrong.)
>
> Not exactly. When the arithmetic evaluator enc
Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: darwin13.4.0
Compiler: clang
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64'
-DCONF_OSTYPE='darwin13.4.0' -DCONF_MACHTYPE='x86_64-apple-darwin13.4.0'
-DCONF_VENDOR='apple'
-DLOCALEDIR='/usr/local/
Robert Parker wrote:
> Yet when I attempt the same in a C program, the system always writes
> 2 prompts, then waits for a read.
> Does not matter if I write(1, "..."); read(0, number, buffer); or use
> fputs("...", stdout); fgets(.
> The result is the same.
> And I have tried using readline wit
Thanks guys.
Code supplied:
static void getuserinput(char *prompt, char *reply);
static int getans(char *prompt, char *choices);
int main(int argc, char **argv)
{
char namebuf[NAME_MAX];
char typebuf[NAME_MAX];
char defltbuf[NAME_MAX];
char codebuf[NAME_MAX];
char *eols = "\
Robert Parker wrote:
> fputs(shortprompt, stdout);
> fflush(stdin);
Uhm... fflush'ing stdin? That doesn't make sense. Obviously you
meant to flush stdout.
fputs(shortprompt, stdout);
fflush(stdout);
That is likely the specific problem. Unfortunately I have no
On 9/2/15 2:14 PM, Clint Hepner wrote:
> Bash Version: 4.3
> Patch Level: 30
> Release Status: release
>
> Description:
>Unexpected word splitting in here string. According to the man page,
> "Pathname expansion and word splitting are not performed." This is
> essentially the same wordin
On 09/02/2015 02:22 PM, Bob Proulx wrote:
> Robert Parker wrote:
>> fputs(shortprompt, stdout);
>> fflush(stdin);
>
> Uhm... fflush'ing stdin? That doesn't make sense.
There is one case where fflush(stdin) is useful on a terminal: it lets
you discard any pending input. For exam
Am 02.09.2015, 14:19 Uhr,SCHRIEB Chet Ramey :
echo $'\c?' |od -a
echo $'\c[\c\\c]\c^\c_\c?' |od -a
bash prints:
000 us nl
002
000 esc fs c ] rs us us nl
I'd expect:
000 del nl
002
000 esc fs gs rs us del nl
Also the ] in the output seems wrong, looks
On 09/02/2015 03:10 PM, Helmut Karlowski wrote:
>>
>> The Posix standardization of $'...' requires that the character after the
>
> Where is that described? I could not find anything about $'...' in the
> posix-docs.
http://austingroupbugs.net/view.php?id=249
It's not part of POSIX yet; but the
Sorry, I didn't understand your reply. What I'm saying is this: \? is shown in
printf section:
"Causes printf to expand backslash escape sequences in the corresponding
argument, except that ‘\c’ terminates output, backslashes in ‘\'’, ‘\"’, and
‘\?’ are not removed, and octal escapes beginning
On 10.08.2015 22:19, Chet Ramey wrote:
On 8/9/15 1:37 PM, aixtools wrote:
Hi,
Via google I came across the define named
config-top.h:/* #define SYSLOG_HISTORY */
Changing it (manually) to
config-top.h:#define SYSLOG_HISTORY
Adds syslog statements such as:
Aug 9 16:52:55 x064 user:info syslo
21 matches
Mail list logo