On 02/28/2013 01:15 AM, MORITA Kazutaka wrote:
> + sd_eprintf("Set /proc/sys/kernel/yama/ptrace_scope to"
> +" zero if you are using Ubuntu.");
I don't have /proc/sys/kernel/yama/ptrace_scope in my Ubuntu. I am using
12.04.
Thanks,
Yuan
--
shee
On 02/28/2013 03:07 PM, MORITA Kazutaka wrote:
> __sys is actually a variable whose type is struct cluster_info, isn't
> it?
>
> static struct cluster_info __sys;
>
> sd_dump_variable can be used against more things than 'state'. We can
> use it to dump any kinds of global and local variables
At Thu, 28 Feb 2013 14:25:22 +0800,
Liu Yuan wrote:
>
> On 02/28/2013 01:15 AM, MORITA Kazutaka wrote:
> > This introduces sd_dump_variable to dump a variable and call it
> > against __sys in crash_handler.
>
> __sys is not a variable but more a compound structure. Maybe
> sd_dump_state is more p
At Thu, 28 Feb 2013 14:18:08 +0800,
Liu Yuan wrote:
>
> On 02/28/2013 01:15 AM, MORITA Kazutaka wrote:
> > +#define sd_dump_variable(var) ({ \
> > + register void *current_sp asm("rsp"); \
> > + __sd_dump_variable(#var, current_sp); \
> > +})
> > +int __sd_dump_variable(const cha
On 02/28/2013 01:15 AM, MORITA Kazutaka wrote:
> This introduces sd_dump_variable to dump a variable and call it
> against __sys in crash_handler.
__sys is not a variable but more a compound structure. Maybe
sd_dump_state is more proper to indicate it is internal information?
Thanks,
Yuan
--
she
On 02/28/2013 01:15 AM, MORITA Kazutaka wrote:
> +#define sd_dump_variable(var) ({ \
> + register void *current_sp asm("rsp"); \
> + __sd_dump_variable(#var, current_sp); \
> +})
> +int __sd_dump_variable(const char *var, const void *base_sp);
Why use macro instead of a inl
This introduces sd_dump_variable to dump a variable and call it
against __sys in crash_handler.
Signed-off-by: MORITA Kazutaka
---
include/logger.h | 6 ++
lib/logger.c | 45 +
sheep/sheep.c| 1 +
3 files changed, 52 insertions(+)
diff -
Signed-off-by: MORITA Kazutaka
---
lib/logger.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/logger.c b/lib/logger.c
index 57e0a09..0dd9422 100644
--- a/lib/logger.c
+++ b/lib/logger.c
@@ -33,6 +33,7 @@
#include
#include
#include
+#include
#include "logger
This is necessary because sd_backtrace assumes that the top of the
stack frames belongs to itself.
Signed-off-by: MORITA Kazutaka
---
lib/logger.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/logger.c b/lib/logger.c
index 0dd9422..a29eaaa 100644
--- a/lib/logger.c
+++ b/lib/logger.c
@
This patch dumps function arguments and local variabls for each stack,
and cluster info with GDB when the program terminates unexpectedly.
Example:
If the following diff is added,
==
--- a/sheep/sheep.c
+++ b/sheep/sheep.c
@@ -719,6 +719,7 @@ int main(int argc, char **argv)
check_host_env
This dumps all function arguments and local variables for each stack
frame using GDB.
Signed-off-by: MORITA Kazutaka
---
lib/logger.c | 91 ++--
1 file changed, 89 insertions(+), 2 deletions(-)
diff --git a/lib/logger.c b/lib/logger.c
inde
11 matches
Mail list logo