本文整理汇总了C++中report_bug函数的典型用法代码示例。如果您正苦于以下问题:C++ report_bug函数的具体用法?C++ report_bug怎么用?C++ report_bug使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了report_bug函数的16个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: rb_compile_bug
void
rb_compile_bug(const char *file, int line, const char *fmt, ...)
{
report_bug(file, line, fmt, NULL);
abort();
}
开发者ID:knugie,项目名称:ruby,代码行数:7,代码来源:error.c
示例2: do_report_trap
void do_report_trap(struct pt_regs *regs, int si_signo, int si_code, char *str)
{
siginfo_t info;
if (user_mode(regs)) {
info.si_signo = si_signo;
info.si_errno = 0;
info.si_code = si_code;
info.si_addr = get_trap_ip(regs);
force_sig_info(si_signo, &info, current);
report_user_fault(regs, si_signo);
} else {
const struct exception_table_entry *fixup;
fixup = search_exception_tables(regs->psw.addr & PSW_ADDR_INSN);
if (fixup)
regs->psw.addr = extable_fixup(fixup) | PSW_ADDR_AMODE;
else {
enum bug_trap_type btt;
btt = report_bug(regs->psw.addr & PSW_ADDR_INSN, regs);
if (btt == BUG_TRAP_TYPE_WARN)
return;
die(regs, str);
}
}
}
开发者ID:lilinj2000,项目名称:linux-4.3.3,代码行数:26,代码来源:traps.c
示例3: die
/*
* This function is protected against re-entrancy.
*/
void die(const char *str, struct pt_regs *regs, int err)
{
enum bug_trap_type bug_type = BUG_TRAP_TYPE_NONE;
struct thread_info *thread = current_thread_info();
int ret;
oops_enter();
raw_spin_lock_irq(&die_lock);
console_verbose();
bust_spinlocks(1);
if (!user_mode(regs))
bug_type = report_bug(regs->pc, regs);
if (bug_type != BUG_TRAP_TYPE_NONE)
str = "Oops - BUG";
ret = __die(str, err, thread, regs);
if (regs && kexec_should_crash(thread->task))
crash_kexec(regs);
bust_spinlocks(0);
add_taint(TAINT_DIE, LOCKDEP_NOW_UNRELIABLE);
raw_spin_unlock_irq(&die_lock);
oops_exit();
if (in_interrupt())
panic("Fatal exception in interrupt");
if (panic_on_oops)
panic("Fatal exception");
if (ret != NOTIFY_STOP)
do_exit(SIGSEGV);
}
开发者ID:1paul1,项目名称:dynamite,代码行数:37,代码来源:traps.c
示例4: rb_compile_bug
void
rb_compile_bug(const char *file, int line, const char *fmt, ...)
{
va_list args;
va_start(args, fmt);
report_bug(file, line, fmt, args);
va_end(args);
abort();
}
开发者ID:technohippy,项目名称:oruby,代码行数:11,代码来源:error.c
示例5: rb_bug
void
rb_bug(const char *fmt, ...)
{
va_list args;
va_start(args, fmt);
report_bug(rb_sourcefile(), rb_sourceline(), fmt, args);
va_end(args);
abort();
}
开发者ID:technohippy,项目名称:oruby,代码行数:11,代码来源:error.c
示例6: handle_BUG
static void handle_BUG(struct pt_regs *regs)
{
enum bug_trap_type tt;
tt = report_bug(regs->pc, regs);
if (tt == BUG_TRAP_TYPE_WARN) {
regs->pc += instruction_size(regs->pc);
return;
}
die("Kernel BUG", regs, TRAPA_BUG_OPCODE & 0xff);
}
开发者ID:274914765,项目名称:C,代码行数:11,代码来源:traps.c
示例7: die
/*
* This is gone through when something in the kernel has done something bad
* and is about to be terminated:
*/
void die(const char *str, struct pt_regs *regs, long err)
{
unsigned long flags = oops_begin();
int sig = SIGSEGV;
if (!user_mode_vm(regs))
report_bug(regs->ip, regs);
if (__die(str, regs, err))
sig = 0;
oops_end(flags, regs, sig);
}
开发者ID:nosnilwar,项目名称:linux-raw-gov-2.6.38.8,代码行数:16,代码来源:dumpstack.c
示例8: rb_bug
void
rb_bug(const char *fmt, ...)
{
const char *file = NULL;
int line = 0;
if (GET_THREAD()) {
file = rb_sourcefile();
line = rb_sourceline();
}
report_bug(file, line, fmt, NULL);
die();
}
开发者ID:knugie,项目名称:ruby,代码行数:15,代码来源:error.c
示例9: die
void die(const char *str, struct pt_regs *fp, unsigned long err)
{
static int diecount;
oops_enter();
console_verbose();
spin_lock_irq(&die_lock);
report_bug(fp->pc, fp);
printk(KERN_EMERG "%s: %04lx [#%d] ", str, err & 0xffff, ++diecount);
dump(fp);
spin_unlock_irq(&die_lock);
do_exit(SIGSEGV);
}
开发者ID:007kumarraja,项目名称:rockchip-rk3188-mk908,代码行数:15,代码来源:traps.c
示例10: rb_bug
void
rb_bug(const char *fmt, ...)
{
va_list args;
va_start(args, fmt);
report_bug(rb_sourcefile(), rb_sourceline(), fmt, args);
va_end(args);
#if defined(_WIN32) && defined(RT_VER) && RT_VER >= 80
_set_abort_behavior( 0, _CALL_REPORTFAULT);
#endif
abort();
}
开发者ID:nurse,项目名称:ruby,代码行数:15,代码来源:error.c
示例11: rb_bug_context
void
rb_bug_context(const void *ctx, const char *fmt, ...)
{
const char *file = NULL;
int line = 0;
if (GET_THREAD()) {
file = rb_sourcefile();
line = rb_sourceline();
}
report_bug(file, line, fmt, ctx);
die();
}
开发者ID:knugie,项目名称:ruby,代码行数:15,代码来源:error.c
示例12: rb_bug
void
rb_bug(const char *fmt, ...)
{
va_list args;
const char *file = NULL;
int line = 0;
if (GET_THREAD()) {
file = rb_sourcefile();
line = rb_sourceline();
}
va_start(args, fmt);
report_bug(file, line, fmt, args);
va_end(args);
#if defined(_WIN32) && defined(RT_VER) && RT_VER >= 80
_set_abort_behavior( 0, _CALL_REPORTFAULT);
#endif
abort();
}
开发者ID:evan,项目名称:ruby,代码行数:22,代码来源:error.c
示例13: bug_handler
static int bug_handler(struct pt_regs *regs, unsigned int esr)
{
if (user_mode(regs))
return DBG_HOOK_ERROR;
switch (report_bug(regs->pc, regs)) {
case BUG_TRAP_TYPE_BUG:
die("Oops - BUG", regs, 0);
break;
case BUG_TRAP_TYPE_WARN:
/* Ideally, report_bug() should backtrace for us... but no. */
dump_backtrace(regs, NULL);
break;
default:
/* unknown/unrecognised bug trap type */
return DBG_HOOK_ERROR;
}
/* If thread survives, skip over the BUG instruction and continue: */
regs->pc += AARCH64_INSN_SIZE; /* skip BRK and resume */
return DBG_HOOK_HANDLED;
}
开发者ID:fromfuture,项目名称:Elizium,代码行数:24,代码来源:traps.c
示例14: handle_BUG
static void handle_BUG(struct pt_regs *regs)
{
const struct bug_entry *bug;
unsigned long bugaddr = regs->pc;
enum bug_trap_type tt;
if (!is_valid_bugaddr(bugaddr))
goto invalid;
bug = find_bug(bugaddr);
/* Switch unwinders when unwind_stack() is called */
if (bug->flags & BUGFLAG_UNWINDER)
unwinder_faulted = 1;
tt = report_bug(bugaddr, regs);
if (tt == BUG_TRAP_TYPE_WARN) {
regs->pc += instruction_size(bugaddr);
return;
}
invalid:
die("Kernel BUG", regs, TRAPA_BUG_OPCODE & 0xff);
}
开发者ID:150balbes,项目名称:Amlogic_s905-kernel,代码行数:24,代码来源:traps.c
示例15: trap_c
//.........这里部分代码省略.........
sig = SIGTRAP;
CHK_DEBUGGER_TRAP_MAYBE();
if (kernel_mode_regs(fp))
goto traps_done;
else
break;
case VEC_OVFLOW:
info.si_code = TRAP_TRACEFLOW;
sig = SIGTRAP;
strerror = KERN_NOTICE EXC_0x11(KERN_NOTICE);
CHK_DEBUGGER_TRAP_MAYBE();
break;
case VEC_UNDEF_I:
#ifdef CONFIG_BUG
if (kernel_mode_regs(fp)) {
switch (report_bug(fp->pc, fp)) {
case BUG_TRAP_TYPE_NONE:
break;
case BUG_TRAP_TYPE_WARN:
dump_bfin_trace_buffer();
fp->pc += 2;
goto traps_done;
case BUG_TRAP_TYPE_BUG:
panic("BUG()");
}
}
#endif
#ifdef CONFIG_BFIN_PSEUDODBG_INSNS
if (!kernel_mode_regs(fp) && get_instruction(&opcode, (unsigned short *)fp->pc)) {
if (execute_pseudodbg_assert(fp, opcode))
goto traps_done;
if (execute_pseudodbg(fp, opcode))
goto traps_done;
}
#endif
info.si_code = ILL_ILLOPC;
sig = SIGILL;
strerror = KERN_NOTICE EXC_0x21(KERN_NOTICE);
CHK_DEBUGGER_TRAP_MAYBE();
break;
case VEC_ILGAL_I:
info.si_code = ILL_ILLPARAOP;
sig = SIGILL;
strerror = KERN_NOTICE EXC_0x22(KERN_NOTICE);
CHK_DEBUGGER_TRAP_MAYBE();
break;
开发者ID:Blackburn29,项目名称:PsycoKernel,代码行数:66,代码来源:traps.c
示例16: wm_command
//.........这里部分代码省略.........
case ID_RESTORE_DEFAULT_SETTINGS:
g_Settings.restore_defaults();
break;
case ID_SETTINGS_MOUSEOVER:
{
cDlgMouseOver d;
d.make_dlg();
}
break;
case ID_HIDE_HOTKEYNET:
set_tray_icon ();
ShowWindow ( g_hwnd, SW_HIDE );
break;
case ID_TOGGLE_SHOW_STATE:
ShowWindow ( g_hwnd, IsWindowVisible(g_hwnd) ? SW_HIDE : SW_RESTORE );
break;
case ID_TOGGLE_HOTKEYS:
toggle_hotkeys();
break;
case ID_DEBUG:
debug();
break;
case ID_ASK_QUESTION:
show_forum();
break;
case ID_REPORT_BUG:
report_bug ();
break;
case ID_INSTRUCTIONS:
show_instructions ();
break;
case ID_SETTINGS_CONNECTION:
{
cDlgSettingsConnection d;
d.make_dlg();
}
break;
case ID_SETTINGS_SECURITY:
{
cDlgSettingsSecurity d;
d.make_dlg();
}
break;
case ID_SETTINGS_START_UP:
{
cDlgSettingsStartUp d;
d.make_dlg();
}
break;
case ID_SETTINGS_DISPLAY:
{
cDlgSettingsDisplay d;
d.make_dlg();
}
开发者ID:XueSlick,项目名称:mojoware,代码行数:67,代码来源:cWinMain_wm_command.cpp
注:本文中的report_bug函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论