luasandbox
1.4.0
Generic Lua sandbox for dynamic data analysis
Main Page
Classes
Files
File List
File Members
include
luasandbox
error.h
Go to the documentation of this file.
1
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/* vim: set ts=2 et sw=2 tw=80: */
3
/* This Source Code Form is subject to the terms of the Mozilla Public
4
* License, v. 2.0. If a copy of the MPL was not distributed with this
5
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7
/** Error handling and logging @file */
8
9
#ifndef luasandbox_error_h_
10
#define luasandbox_error_h_
11
12
// See Identify your Errors better with char[]
13
// http://accu.org/index.php/journals/2184
14
typedef
const
char
lsb_err_id
[];
15
typedef
const
char
*
lsb_err_value
;
16
#define lsb_err_string(s) s ? s : "<no error>"
17
18
typedef
void (*
lsb_logger_cb
)(
void
*context,
19
const
char
*component,
20
int
level,
21
const
char
*fmt,
22
...);
23
24
typedef
struct
lsb_logger
{
25
void
*
context
;
26
lsb_logger_cb
cb
;
27
}
lsb_logger
;
28
29
#endif
lsb_err_value
const char * lsb_err_value
Definition:
error.h:15
lsb_logger
Definition:
error.h:24
lsb_logger_cb
void(* lsb_logger_cb)(void *context, const char *component, int level, const char *fmt,...)
Definition:
error.h:18
lsb_err_id
const char lsb_err_id[]
Definition:
error.h:14
lsb_logger::cb
lsb_logger_cb cb
Definition:
error.h:26
lsb_logger::context
void * context
Definition:
error.h:25
lsb_logger
struct lsb_logger lsb_logger
Generated by
1.8.11