FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Crash Utility

 
 
LinkBack Thread Tools
 
Old 04-06-2012, 09:28 AM
"Imap"
 
Default Patch to add comments

Hello Dave,
A small cosmetic pach to add comments in the crash
flow.
Of course we may use !# to do this, but to call a shell
just for a comment seems rather hard ?
*
*
*
With !#, we have:
*
crash> !#
crash> !# sysrq-triger
crash> !#
crash> file_operations 0xffffffff81643300
struct file_operations {
owner = 0x0,
llseek = 0xffffffff81166b90 <noop_llseek>,
read = 0,
write = 0xffffffff812fa4b0 <write_sysrq_trigger>,
[...]
}After the introduction of the
command #, we just have:*
*
crash> #
crash> # sysrq-triger
crash> #
crash> file_operations 0xffffffff81643300
struct file_operations {
owner = 0x0,
llseek = 0xffffffff81166b90 <noop_llseek>,
read = 0,
write = 0xffffffff812fa4b0 <write_sysrq_trigger>,
[...]
}
--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-10-2012, 02:07 PM
Dave Anderson
 
Default Patch to add comments

----- Original Message -----
>
>
> Hello Dave,
> A small cosmetic pach to add comments in the crash flow.
> Of course we may use !# to do this, but to call a shell just for a
> comment seems rather hard ?

True -- but your patch that makes "#" an actual command is way-overkill.

Why not do this:

--- main.c 20 Mar 2012 18:11:46 -0000 1.130
+++ main.c 10 Apr 2012 13:59:45 -0000
@@ -768,6 +768,9 @@ exec_command(void)
if (is_datatype_command())
goto reattempt;

+ if (STRNEQ(args[0], "#"))
+ return;
+
if (!(pc->flags & MINIMAL_MODE) &&
is_gdb_command(TRUE, FAULT_ON_ERROR))
goto reattempt;

Dave



--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-10-2012, 02:33 PM
Olivier Daudel
 
Default Patch to add comments

Dave Anderson <anderson@redhat.com> a écrit :




----- Original Message -----



Hello Dave,
A small cosmetic pach to add comments in the crash flow.
Of course we may use !# to do this, but to call a shell just for a
comment seems rather hard ?


True -- but your patch that makes "#" an actual command is way-overkill.

Why not do this:

--- main.c 20 Mar 2012 18:11:46 -0000 1.130
+++ main.c 10 Apr 2012 13:59:45 -0000
@@ -768,6 +768,9 @@ exec_command(void)
if (is_datatype_command())
goto reattempt;

+ if (STRNEQ(args[0], "#"))
+ return;
+
if (!(pc->flags & MINIMAL_MODE) &&
is_gdb_command(TRUE, FAULT_ON_ERROR))
goto reattempt;

Dave



--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility


Thanks, simple is better!
Nevertheless, do we keep something in the help file or do we just
"know" the way to push comment ?

Olivier


----------------------------------------------------------------
Ce message a ete envoye par IMP, grace a l'Universite Paris Ouest.




--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-10-2012, 02:44 PM
Dave Anderson
 
Default Patch to add comments

----- Original Message -----
>
>
> Dave Anderson <anderson@redhat.com> a écrit :
>
> >
> >
> > ----- Original Message -----
> >>
> >>
> >> Hello Dave,
> >> A small cosmetic pach to add comments in the crash flow.
> >> Of course we may use !# to do this, but to call a shell just for a
> >> comment seems rather hard ?
> >
> > True -- but your patch that makes "#" an actual command is
> > way-overkill.
> >
> > Why not do this:
> >
> > --- main.c 20 Mar 2012 18:11:46 -0000 1.130
> > +++ main.c 10 Apr 2012 13:59:45 -0000
> > @@ -768,6 +768,9 @@ exec_command(void)
> > if (is_datatype_command())
> > goto reattempt;
> >
> > + if (STRNEQ(args[0], "#"))
> > + return;
> > +
> > if (!(pc->flags & MINIMAL_MODE) &&
> > is_gdb_command(TRUE, FAULT_ON_ERROR))
> > goto reattempt;
> >
> > Dave
> >
> >
> >
> > --
> > Crash-utility mailing list
> > Crash-utility@redhat.com
> > https://www.redhat.com/mailman/listinfo/crash-utility
> >
> Thanks, simple is better!
> Nevertheless, do we keep something in the help file or do we just
> "know" the way to push comment ?
> Olivier

A line should probably be added to the "help input" page,
which is the input_info[] string array in help.c.

Dave



--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-16-2012, 09:30 AM
"Olivier Daudel"
 
Default Patch to add comments

The patch with your advises.
Olivier


--------------------------------------------------
From: "Dave Anderson" <anderson@redhat.com>
Sent: Tuesday, April 10, 2012 4:44 PM
To: "Discussion list for crash utility usage,maintenance and development"
<crash-utility@redhat.com>

Subject: Re: [Crash-utility] Patch to add comments




----- Original Message -----



Dave Anderson <anderson@redhat.com> a écrit :

>
>
> ----- Original Message -----
>>
>>
>> Hello Dave,
>> A small cosmetic pach to add comments in the crash flow.
>> Of course we may use !# to do this, but to call a shell just for a
>> comment seems rather hard ?
>
> True -- but your patch that makes "#" an actual command is
> way-overkill.
>
> Why not do this:
>
> --- main.c 20 Mar 2012 18:11:46 -0000 1.130
> +++ main.c 10 Apr 2012 13:59:45 -0000
> @@ -768,6 +768,9 @@ exec_command(void)
> if (is_datatype_command())
> goto reattempt;
>
> + if (STRNEQ(args[0], "#"))
> + return;
> +
> if (!(pc->flags & MINIMAL_MODE) &&
> is_gdb_command(TRUE, FAULT_ON_ERROR))
> goto reattempt;
>
> Dave
>
>
>
> --
> Crash-utility mailing list
> Crash-utility@redhat.com
> https://www.redhat.com/mailman/listinfo/crash-utility
>
Thanks, simple is better!
Nevertheless, do we keep something in the help file or do we just
"know" the way to push comment ?
Olivier


A line should probably be added to the "help input" page,
which is the input_info[] string array in help.c.

Dave



--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-16-2012, 10:21 AM
"Olivier Daudel"
 
Default Patch to add comments

Sorry, but just after sending the patch with bash style comments "#", i was
thinking we could also have c style comments wiht "//". In that way, we may
choose comment style when we use colored syntax for crash.

Thanks.

--------------------------------------------------
From: "Dave Anderson" <anderson@redhat.com>
Sent: Tuesday, April 10, 2012 4:44 PM
To: "Discussion list for crash utility usage,maintenance and development"
<crash-utility@redhat.com>

Subject: Re: [Crash-utility] Patch to add comments




----- Original Message -----



Dave Anderson <anderson@redhat.com> a écrit :

>
>
> ----- Original Message -----
>>
>>
>> Hello Dave,
>> A small cosmetic pach to add comments in the crash flow.
>> Of course we may use !# to do this, but to call a shell just for a
>> comment seems rather hard ?
>
> True -- but your patch that makes "#" an actual command is
> way-overkill.
>
> Why not do this:
>
> --- main.c 20 Mar 2012 18:11:46 -0000 1.130
> +++ main.c 10 Apr 2012 13:59:45 -0000
> @@ -768,6 +768,9 @@ exec_command(void)
> if (is_datatype_command())
> goto reattempt;
>
> + if (STRNEQ(args[0], "#"))
> + return;
> +
> if (!(pc->flags & MINIMAL_MODE) &&
> is_gdb_command(TRUE, FAULT_ON_ERROR))
> goto reattempt;
>
> Dave
>
>
>
> --
> Crash-utility mailing list
> Crash-utility@redhat.com
> https://www.redhat.com/mailman/listinfo/crash-utility
>
Thanks, simple is better!
Nevertheless, do we keep something in the help file or do we just
"know" the way to push comment ?
Olivier


A line should probably be added to the "help input" page,
which is the input_info[] string array in help.c.

Dave



--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 
Old 04-16-2012, 02:48 PM
Dave Anderson
 
Default Patch to add comments

----- Original Message -----
> Sorry, but just after sending the patch with bash style comments "#", i was
> thinking we could also have c style comments wiht "//". In that way, we may
> choose comment style when we use colored syntax for crash.
> Thanks.

Sure, why not? Queued for crash-6.0.6.

Thanks,
Dave

>
> --------------------------------------------------
> From: "Dave Anderson" <anderson@redhat.com>
> Sent: Tuesday, April 10, 2012 4:44 PM
> To: "Discussion list for crash utility usage,maintenance and
> development"
> <crash-utility@redhat.com>
> Subject: Re: [Crash-utility] Patch to add comments
>
> >
> >
> > ----- Original Message -----
> >>
> >>
> >> Dave Anderson <anderson@redhat.com> a écrit :
> >>
> >> >
> >> >
> >> > ----- Original Message -----
> >> >>
> >> >>
> >> >> Hello Dave,
> >> >> A small cosmetic pach to add comments in the crash flow.
> >> >> Of course we may use !# to do this, but to call a shell just
> >> >> for a
> >> >> comment seems rather hard ?
> >> >
> >> > True -- but your patch that makes "#" an actual command is
> >> > way-overkill.
> >> >
> >> > Why not do this:
> >> >
> >> > --- main.c 20 Mar 2012 18:11:46 -0000 1.130
> >> > +++ main.c 10 Apr 2012 13:59:45 -0000
> >> > @@ -768,6 +768,9 @@ exec_command(void)
> >> > if (is_datatype_command())
> >> > goto reattempt;
> >> >
> >> > + if (STRNEQ(args[0], "#"))
> >> > + return;
> >> > +
> >> > if (!(pc->flags & MINIMAL_MODE) &&
> >> > is_gdb_command(TRUE, FAULT_ON_ERROR))
> >> > goto reattempt;
> >> >
> >> > Dave
> >> >
> >> >
> >> >
> >> > --
> >> > Crash-utility mailing list
> >> > Crash-utility@redhat.com
> >> > https://www.redhat.com/mailman/listinfo/crash-utility
> >> >
> >> Thanks, simple is better!
> >> Nevertheless, do we keep something in the help file or do we just
> >> "know" the way to push comment ?
> >> Olivier
> >
> > A line should probably be added to the "help input" page,
> > which is the input_info[] string array in help.c.
> >
> > Dave
> >
> >
> >
> > --
> > Crash-utility mailing list
> > Crash-utility@redhat.com
> > https://www.redhat.com/mailman/listinfo/crash-utility
> >
> --
> Crash-utility mailing list
> Crash-utility@redhat.com
> https://www.redhat.com/mailman/listinfo/crash-utility
>

--
Crash-utility mailing list
Crash-utility@redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility
 

Thread Tools




All times are GMT. The time now is 06:53 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org