|
INLINE int64 | qatoll (const char *nptr) |
|
INLINE THREAD_SAFE uint32 | get_secs (qtime64_t t) |
| Get the 'seconds since the epoch' part of a qtime64_t.
|
|
INLINE THREAD_SAFE uint32 | get_usecs (qtime64_t t) |
| Get the microseconds part of a qtime64_t.
|
|
INLINE THREAD_SAFE qtime64_t | make_qtime64 (uint32 secs, DEFARG(int32 usecs, 0)) |
| Get a qtime64_t instance from a seconds value and microseconds value. More...
|
|
idaman THREAD_SAFE bool ida_export | qctime (char *buf, size_t bufsize, qtime32_t t) |
| Converts calendar time into a string. More...
|
|
idaman THREAD_SAFE bool ida_export | qctime_utc (char *buf, size_t bufsize, qtime32_t t) |
| Converts calendar time into a string using Coordinated Universal Time (UTC). More...
|
|
idaman THREAD_SAFE bool ida_export | qlocaltime (struct tm *_tm, time_t t) |
| Converts a time value to a tm structure (local time) More...
|
|
INLINE THREAD_SAFE bool | qlocaltime64 (struct tm *_tm, qtime64_t t) |
| Same as qlocaltime(struct tm *, qtime32_t), but accepts a 64-bit time value.
|
|
idaman bool ida_export | qgmtime (struct tm *_tm, time_t t) |
| Converts a time value to a tm structure (UTC time) More...
|
|
INLINE THREAD_SAFE bool | qgmtime64 (struct tm *_tm, qtime64_t t) |
| Same as qgmtime(struct tm *, time_t), but accepts a 64-bit time value.
|
|
idaman time_t ida_export | qtimegm (const struct tm *ptm) |
|
idaman | AS_STRFTIME (3) THREAD_SAFE size_t ida_export qstrftime(char *buf |
| Get string representation of a time_t (local time) Copies into 'buf' the content of 'format', expanding its format specifiers into the corresponding values that represent the time described in 't', with a limit of 'bufsize' characters see http://www.cplusplus.com/reference/ctime/strftime/ for more. More...
|
|
idaman THREAD_SAFE void ida_export | qsleep (int milliseconds) |
| Suspend execution for given number of milliseconds.
|
|
idaman THREAD_SAFE uint64 ida_export | get_nsec_stamp (void) |
| High resolution timer. More...
|
|
idaman THREAD_SAFE qtime64_t ida_export | qtime64 (void) |
| Get the current time with microsecond resolution (in fact the resolution is worse on windows)
|
|
idaman THREAD_SAFE bool ida_export | gen_rand_buf (void *buffer, size_t bufsz) |
| Generate a random buffer. More...
|
|
idaman THREAD_SAFE error_t ida_export | set_qerrno (error_t code) |
| Set qerrno.
|
|
idaman THREAD_SAFE error_t ida_export | get_qerrno (void) |
| Get qerrno.
|
|
idaman THREAD_SAFE NORETURN void ida_export | interr (int code) |
| Show internal error message and terminate execution.
|
|
idaman THREAD_SAFE bool ida_export | set_interr_throws (bool enable) |
|
idaman THREAD_SAFE void *ida_export | qalloc (size_t size) |
| System independent malloc.
|
|
idaman THREAD_SAFE void *ida_export | qrealloc (void *alloc, size_t newsize) |
| System independent realloc.
|
|
idaman THREAD_SAFE void *ida_export | qcalloc (size_t nitems, size_t itemsize) |
| System independent calloc.
|
|
idaman THREAD_SAFE void ida_export | qfree (void *alloc) |
| System independent free.
|
|
idaman THREAD_SAFE char *ida_export | qstrdup (const char *string) |
| System independent strdup.
|
|
template<class T > |
T * | qalloc_array (size_t n) |
| Use this class to avoid integer overflows when allocating arrays.
|
|
template<class T > |
T * | qrealloc_array (T *ptr, size_t n) |
| Use this class to avoid integer overflows when allocating arrays.
|
|
idaman THREAD_SAFE void *ida_export | memrev (void *buf, ssize_t size) |
| Reverse memory block. More...
|
|
idaman THREAD_SAFE char *ida_export | strrpl (char *str, int char1, int char2) |
| Replace all occurrences of a character within a string. More...
|
|
INLINE THREAD_SAFE char * | tail (char *str) |
| Get tail of a string.
|
|
THREAD_SAFE const char * | tail (const char *str) |
| Get tail of a string. More...
|
|
idaman THREAD_SAFE char *ida_export | qstrncpy (char *dst, const char *src, size_t dstsize) |
| A safer strncpy - makes sure that there is a terminating zero. More...
|
|
idaman THREAD_SAFE char *ida_export | qstpncpy (char *dst, const char *src, size_t dstsize) |
| A safer stpncpy - returns pointer to the end of the destination nb: ssize_t(dstsize) must be > 0.
|
|
idaman THREAD_SAFE char *ida_export | qstrncat (char *dst, const char *src, size_t dstsize) |
| A safer strncat - accepts the size of the 'dst' as 'dstsize' and returns dst nb: ssize_t(dstsize) must be > 0.
|
|
idaman THREAD_SAFE char *ida_export | qstrtok (char *s, const char *delim, char **save_ptr) |
| Thread-safe version of strtok.
|
|
idaman THREAD_SAFE char *ida_export | qstrlwr (char *str) |
| Convert the string to lowercase.
|
|
idaman THREAD_SAFE char *ida_export | qstrupr (char *str) |
| Convert the string to uppercase.
|
|
idaman THREAD_SAFE const char *ida_export | stristr (const char *s1, const char *s2) |
| Find one string in another (Case insensitive analog of strstr()). More...
|
|
char *idaapi | stristr (char *s1, const char *s2) |
| Same as stristr(const char *, const char *) but returns a non-const result.
|
|
INLINE THREAD_SAFE bool ida_local | qisascii (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisspace (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisalpha (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisalnum (char c) |
|
INLINE THREAD_SAFE bool ida_local | qispunct (char c) |
|
INLINE THREAD_SAFE bool ida_local | qislower (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisupper (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisprint (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisdigit (char c) |
|
INLINE THREAD_SAFE bool ida_local | qisxdigit (char c) |
|
INLINE THREAD_SAFE int ida_local | qtolower (char c) |
| Get lowercase equivalent of given char.
|
|
INLINE THREAD_SAFE int ida_local | qtoupper (char c) |
| Get uppercase equivalent of given char.
|
|
idaman THREAD_SAFE int ida_export | qsnprintf (char *buffer, size_t n, const char *format,...) |
| A safer snprintf.
|
|
idaman THREAD_SAFE int ida_export | qsscanf (const char *input, const char *format,...) |
| A safer sscanf.
|
|
idaman THREAD_SAFE int ida_export | qvsnprintf (char *buffer, size_t n, const char *format, va_list va) |
| See qsnprintf()
|
|
idaman THREAD_SAFE int ida_export | qvsscanf (const char *input, const char *format, va_list va) |
| See qsscanf()
|
|
idaman THREAD_SAFE int ida_export | append_snprintf (char *buf, const char *end, const char *format,...) |
| Append result of sprintf to 'buf'.
|
|
| GCC_DIAG_OFF (format-nonliteral) |
| qsnprintf that does not check its arguments. More...
|
|
INLINE int | nowarn_qsnprintf (char *buf, size_t size, const char *format,...) |
|
| GCC_DIAG_ON (format-nonliteral) |
|
idaman THREAD_SAFE char *ida_export | vqmakepath (char *buf, size_t bufsize, const char *s1, va_list) |
| See qmakepath()
|
|
idaman THREAD_SAFE char *ida_export | qmakepath (char *buf, size_t bufsize, const char *s1,...) |
| Construct a path from a null-terminated sequence of strings. More...
|
|
idaman void ida_export | qgetcwd (char *buf, size_t bufsize) |
| Get the current working directory. More...
|
|
idaman int ida_export | qchdir (const char *path) |
| Change the current working directory. More...
|
|
idaman THREAD_SAFE bool ida_export | qdirname (char *buf, size_t bufsize, const char *path) |
| Get the directory part of the path. More...
|
|
idaman THREAD_SAFE char *ida_export | qmakefile (char *buf, size_t bufsize, const char *base, const char *ext) |
| Construct filename from base name and extension. More...
|
|
idaman THREAD_SAFE char *ida_export | qsplitfile (char *file, char **base, char **ext) |
| Split filename into base name and extension. More...
|
|
idaman THREAD_SAFE bool ida_export | qisabspath (const char *file) |
| Is the file name absolute (not relative to the current dir?)
|
|
idaman THREAD_SAFE const char *ida_export | qbasename (const char *path) |
| Get the file name part of the given path. More...
|
|
char * | qbasename (char *path) |
| Same as qbasename(const char *), but accepts and returns non-const char pointers.
|
|
idaman THREAD_SAFE char *ida_export | qmake_full_path (char *dst, size_t dstsize, const char *src) |
| Convert relative path to absolute path.
|
|
idaman THREAD_SAFE bool ida_export | search_path (char *buf, size_t bufsize, const char *file, bool search_cwd) |
| Search for a file in the PATH environment variable or the current directory. More...
|
|
idaman THREAD_SAFE char *ida_export | set_file_ext (char *outbuf, size_t bufsize, const char *file, const char *ext) |
| Set file name extension unconditionally. More...
|
|
idaman THREAD_SAFE const char *ida_export | get_file_ext (const char *file) |
| Get pointer to extension of file name. More...
|
|
THREAD_SAFE bool idaapi | has_file_ext (const char *file) |
| Does the given file name have an extension?
|
|
THREAD_SAFE char *idaapi | make_file_ext (char *buf, size_t bufsize, const char *file, const char *ext) |
| Set file name extension if none exists. More...
|
|
idaman THREAD_SAFE bool ida_export | sanitize_file_name (char *name, size_t namesize) |
| Sanitize the file name. More...
|
|
bool | wildcard_match (const char *name, const char *pattern) |
| Match a name against a pattern. More...
|
|
bool | wildcard_path_match (const char *name, const char *_pattern, int flags=0) |
| Match a path against a pattern. More...
|
|
idaman int ida_export | regex_match (const char *str, const char *pattern, bool sense_case) |
| Match a string with a regular expression. More...
|
|
idaman THREAD_SAFE int ida_export | qopen (const char *file, int mode) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE int ida_export | qopen_shared (const char *file, int mode, int share_mode) |
| Open file with given sharing_mode (use O_RDONLY, O_WRONLY, O_RDWR flags), sets qerrno.
|
|
idaman THREAD_SAFE int ida_export | qcreate (const char *file, int stat) |
| Create new file with O_RDWR, sets qerrno.
|
|
idaman THREAD_SAFE int ida_export | qread (int h, void *buf, size_t n) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE int ida_export | qwrite (int h, const void *buf, size_t n) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE qoff64_t ida_export | qtell (int h) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE qoff64_t ida_export | qseek (int h, int64 offset, int whence) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE int ida_export | qclose (int h) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE int ida_export | qdup (int h) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE int ida_export | qfsync (int h) |
| Works the same as it's counterpart from Clib. More...
|
|
idaman THREAD_SAFE uint64 ida_export | qfilesize (const char *fname) |
| Get the file size. More...
|
|
idaman THREAD_SAFE uint64 ida_export | qfilelength (int h) |
| Get file length in bytes. More...
|
|
idaman THREAD_SAFE int ida_export | qchsize (int h, uint64 fsize) |
| Change file size. More...
|
|
idaman THREAD_SAFE int ida_export | qmkdir (const char *file, int mode) |
| Create an empty directory. More...
|
|
idaman THREAD_SAFE int ida_export | qrmdir (const char *file) |
| Delete a directory. More...
|
|
idaman THREAD_SAFE bool ida_export | qfileexist (const char *file) |
| Does the given file exist?
|
|
idaman THREAD_SAFE bool ida_export | qisdir (const char *file) |
| Does the given path specify a directory?
|
|
idaman THREAD_SAFE int ida_export | qstat (const char *path, struct qstatbuf *buf) |
| Get file status.
|
|
idaman THREAD_SAFE int ida_export | qfstat (int fd, struct qstatbuf *buf) |
|
idaman THREAD_SAFE void ida_export | qatexit (void(idaapi *func)(void)) |
| Add a function to be called at exit time.
|
|
idaman THREAD_SAFE void ida_export | del_qatexit (void(idaapi *func)(void)) |
| Remove a previously added exit-time function.
|
|
idaman THREAD_SAFE NORETURN void ida_export | qexit (int code) |
| Call qatexit functions, shut down UI and kernel, and exit. More...
|
|
template<class T > |
T | qabs (T x) |
|
INLINE THREAD_SAFE bool idaapi | test_bit (const uchar *bitmap, size_t bit) |
| Test if 'bit' is set in 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | set_bit (uchar *bitmap, size_t bit) |
| Set 'bit' in 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | clear_bit (uchar *bitmap, size_t bit) |
| Clear 'bit' in 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | set_bits (uchar *bitmap, size_t low, size_t high) |
| Set bits between [low, high) in 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | clear_bits (uchar *bitmap, size_t low, size_t high) |
| Clear bits between [low, high) in 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | set_all_bits (uchar *bitmap, size_t nbits) |
| Set first 'nbits' of 'bitmap'.
|
|
INLINE THREAD_SAFE void idaapi | clear_all_bits (uchar *bitmap, size_t nbits) |
| Clear first 'nbits' of 'bitmap'.
|
|
idaman int ida_export | log2ceil (uint64 d64) |
| calculate ceil(log2(d64)) or floor(log2(d64)), it returns 0 if d64 == 0
|
|
idaman int ida_export | log2floor (uint64 d64) |
|
idaman int ida_export | bitcount (uint64 x) |
| calculate number of set bits (the population count)
|
|
idaman uint32 ida_export | round_up_power2 (uint32 x) |
| round up or down to a power of 2
|
|
idaman uint32 ida_export | round_down_power2 (uint32 x) |
|
template<class T > |
constexpr bool | is_pow2 (T val) |
| is power of 2? (or zero)
|
|
template<class T > |
T | round_up (T val, T base) |
| round up or down to an arbitrary number
|
|
template<class T > |
T | round_down (T val, T base) |
|
THREAD_SAFE constexpr uval_t | interval::last (uval_t off, asize_t s) |
| max offset of the interval (assume s != 0)
|
|
THREAD_SAFE constexpr bool | interval::overlap (uval_t off1, asize_t s1, uval_t off2, asize_t s2) |
| Do (off1,s1) and (off2,s2) overlap?
|
|
THREAD_SAFE constexpr bool | interval::includes (uval_t off1, asize_t s1, uval_t off2, asize_t s2) |
| Does (off1,s1) include (off2,s2)?
|
|
THREAD_SAFE constexpr bool | interval::contains (uval_t off1, asize_t s1, uval_t off) |
| Does (off1,s1) contain off?
|
|
template<class T > |
constexpr T | left_shift (const T &value, int shift) |
| Shift by the amount exceeding the operand size*8 is undefined by the standard. More...
|
|
template<class T > |
constexpr T | right_ushift (const T &value, int shift) |
| Shift by the amount exceeding the operand size*8 is undefined by the standard. More...
|
|
template<class T > |
constexpr T | right_sshift (const T &value, int shift) |
| Shift by the amount exceeding the operand size*8 is undefined by the standard. More...
|
|
template<class T > |
T | qrotl (T value, size_t count) |
| Rotate left.
|
|
template<class T > |
T | qrotr (T value, size_t count) |
| Rotate right.
|
|
template<class T > |
constexpr T | make_mask (int count) |
| Make a mask of 'count' bits.
|
|
template<class T , class U > |
void idaapi | setflag (T &where, U bit, bool cnd) |
| Set a 'bit' in 'where' if 'value' if not zero.
|
|
template<class T > |
bool | is_mul_ok (T count, T elsize) |
| Check that unsigned multiplication does not overflow.
|
|
template<class U , class T > |
bool | is_add_ok (U x, T y) |
| Check that unsigned or unsigned+signed addition does not overflow.
|
|
template<class T > |
bool | is_udiv_ok (T, T b) |
| Check that unsigned division is permissible.
|
|
template<class T > |
bool | is_sdiv_ok (T a, T b) |
| Check that signed division is permissible.
|
|
idaman uint64 ida_export | extend_sign (uint64 v, int nbytes, bool sign_extend) |
| Sign-, or zero-extend the value 'v' to occupy 64 bits. More...
|
|
idaman THREAD_SAFE int ida_export | readbytes (int h, uint32 *res, int size, bool mf) |
| Read at most 4 bytes from file. More...
|
|
idaman THREAD_SAFE int ida_export | writebytes (int h, uint32 l, int size, bool mf) |
| Write at most 4 bytes to file. More...
|
|
idaman THREAD_SAFE int ida_export | read2bytes (int h, uint16 *res, bool mf) |
| Read a 2 byte entity from a file. More...
|
|
THREAD_SAFE constexpr uint32 | swap32 (uint32 x) |
|
THREAD_SAFE constexpr ushort | swap16 (ushort x) |
|
idaman THREAD_SAFE void ida_export | swap_value (void *dst, const void *src, int size) |
| Swap endianness of a given value in memory. More...
|
|
idaman THREAD_SAFE void ida_export | reloc_value (void *value, int size, adiff_t delta, bool mf) |
|
idaman THREAD_SAFE uval_t ida_export | rotate_left (uval_t x, int count, size_t bits, size_t offset) |
| Rotate left - can be used to rotate a value to the right if the count is negative. More...
|
|
template<class T > |
THREAD_SAFE void | qswap (T &a, T &b) |
| Swap 2 objects of the same type using memory copies.
|
|
THREAD_SAFE uchar *idaapi | pack_db (uchar *ptr, uchar *end, uchar x) |
| Pack a byte into a character string. More...
|
|
THREAD_SAFE uchar idaapi | unpack_db (const uchar **pptr, const uchar *end) |
| Unpack a byte from a character string, pack_db()
|
|
idaman THREAD_SAFE uchar *ida_export | pack_dw (uchar *ptr, uchar *end, uint16 x) |
| pack a word, see pack_db()
|
|
idaman THREAD_SAFE uchar *ida_export | pack_dd (uchar *ptr, uchar *end, uint32 x) |
| pack a double word, see pack_db()
|
|
idaman THREAD_SAFE uchar *ida_export | pack_dq (uchar *ptr, uchar *end, uint64 x) |
| pack a quadword, see pack_db()
|
|
idaman THREAD_SAFE ushort ida_export | unpack_dw (const uchar **pptr, const uchar *end) |
| unpack a word, see unpack_db()
|
|
idaman THREAD_SAFE uint32 ida_export | unpack_dd (const uchar **pptr, const uchar *end) |
| unpack a double word, see unpack_db()
|
|
idaman THREAD_SAFE uint64 ida_export | unpack_dq (const uchar **pptr, const uchar *end) |
| unpack a quadword, see unpack_db()
|
|
THREAD_SAFE uchar * | pack_ea (uchar *ptr, uchar *end, ea_t ea) |
| Pack an ea value into a character string, see pack_dd()/pack_dq()
|
|
THREAD_SAFE ea_t | unpack_ea (const uchar **ptr, const uchar *end) |
| Unpack an ea value, see unpack_dd()/unpack_dq()
|
|
THREAD_SAFE ea64_t | unpack_ea64 (const uchar **ptr, const uchar *end) |
| Unpack an ea value (always use 64bit, use delta 1)
|
|
THREAD_SAFE void *idaapi | unpack_obj (void *destbuf, size_t destsize, const uchar **pptr, const uchar *end) |
| Unpack an object of a known size. More...
|
|
THREAD_SAFE void *idaapi | unpack_buf (const uchar **pptr, const uchar *end) |
| Unpack an object of an unknown size (packed with append_buf()). More...
|
|
THREAD_SAFE const void *idaapi | unpack_obj_inplace (const uchar **pptr, const uchar *end, size_t objsize) |
| In-place version of unpack_obj(). More...
|
|
THREAD_SAFE const void *idaapi | unpack_buf_inplace (const uchar **pptr, const uchar *end) |
| In-place version of unpack_buf(). More...
|
|
idaman THREAD_SAFE uchar *ida_export | pack_ds (uchar *ptr, uchar *end, const char *x, size_t len=0) |
| Pack a string. More...
|
|
idaman THREAD_SAFE char *ida_export | unpack_ds (const uchar **pptr, const uchar *end, bool empty_null) |
| Unpack a string. More...
|
|
THREAD_SAFE bool | unpack_ds_to_buf (char *dst, size_t dstsize, const uchar **pptr, const uchar *end) |
| Unpack a string. More...
|
|
idaman THREAD_SAFE bool ida_export | unpack_xleb128 (void *res, int nbits, bool is_signed, const uchar **pptr, const uchar *end) |
| Unpack an LEB128 encoded (DWARF-3 style) signed/unsigned value. More...
|
|
template<class T > |
THREAD_SAFE bool | unpack_uleb128 (T *res, const uchar **pptr, const uchar *end) |
|
template<class T > |
THREAD_SAFE bool | unpack_sleb128 (T *res, const uchar **pptr, const uchar *end) |
|
THREAD_SAFE int | ds_packed_size (const char *s) |
|
THREAD_SAFE constexpr int | dw_size (uchar first_byte) |
|
THREAD_SAFE constexpr int | dd_size (uchar first_byte) |
|
template<class T > |
THREAD_SAFE uchar | extract_db (T &v) |
|
template<class T > |
THREAD_SAFE void * | extract_obj (T &v, void *destbuf, size_t destsize) |
|
template<class T > |
THREAD_SAFE uint16 | extract_dw (T &v) |
|
template<class T > |
THREAD_SAFE uint32 | extract_dd (T &v) |
|
template<class T > |
THREAD_SAFE uint64 | extract_dq (T &v) |
|
template<class T > |
THREAD_SAFE ea_t | extract_ea (T &v) |
|
template<class T > |
THREAD_SAFE void * | extract_buf (T &v, size_t size) |
|
template<class T > |
THREAD_SAFE void * | extract_array (T &v, size_t *sz, size_t maxsize) |
|
const char * | unpack_str (const uchar **pptr, const uchar *end) |
|
idaman THREAD_SAFE void *ida_export | qalloc_or_throw (size_t size) |
| qalloc() 'size' bytes, and throw a "not enough memory" error if failed
|
|
idaman THREAD_SAFE void *ida_export | qrealloc_or_throw (void *ptr, size_t size) |
| qrealloc() 'ptr' by 'size', and throw a "not enough memory" error if failed
|
|
idaman THREAD_SAFE void *ida_export | qvector_reserve (void *vec, void *old, size_t cnt, size_t elsize) |
| Change capacity of given qvector. More...
|
|
template<class T > |
void | shift_down (T *dst, T *src, size_t cnt) |
| Move data down in memory. More...
|
|
template<class T > |
void | shift_up (T *dst, T *src, size_t cnt) |
| Move data up in memory. More...
|
|
template<class T > |
int | lexcompare (const T &a, const T &b) |
| Standard lexical comparison. More...
|
|
template<class T > |
int | lexcompare_vectors (const T &a, const T &b) |
| Lexical comparison of two vectors. More...
|
|
idaman THREAD_SAFE bool ida_export | relocate_relobj (struct relobj_t *_relobj, ea_t ea, bool mf) |
|
THREAD_SAFE void | unpack_eavec (eavec_t *vec, ea_t ea, const uchar **ptr, const uchar *end) |
| Unpack a vector of ea values. More...
|
|
THREAD_SAFE bool | unpack_bytevec (bytevec_t *out, const uchar **pptr, const uchar *end) |
|
bool | unpack_str (qstring *out, const uchar **pptr, const uchar *end) |
|
template<class T , typename std::enable_if< has_compare_method< T >::value, int >::type = 0> |
int | compare (const T &a, const T &b) |
|
template<class T > |
int | compare (const qvector< T > &a, const qvector< T > &b) |
|
template<class T > |
int | compare (const qlist< T > &a, const qlist< T > &b) |
|
template<class T , class U > |
int | compare (const std::pair< T, U > &a, const std::pair< T, U > &b) |
|
template<class T > |
int | compare_containers (const T &l, const T &r) |
| Template to compare any 2 containers of the same type. Returns -1/0/1.
|
|
template<class T , class U > |
int | compare (const std::map< T, U > &a, const std::map< T, U > &b) |
|
template<class T > |
int | compare (const std::set< T > &a, const std::set< T > &b) |
|
template<class T > |
T | align_up (T val, int elsize) |
| Align element up to nearest boundary.
|
|
template<class T > |
T | align_down (T val, int elsize) |
| Align element down to nearest boundary.
|
|
idaman THREAD_SAFE uint32 ida_export | calc_crc32 (uint32 crc, const void *buf, size_t len) |
| Calculate CRC32 (polynom 0xEDB88320, zlib compatible). More...
|
|
idaman THREAD_SAFE uint32 ida_export | calc_file_crc32 (class linput_t *fp) |
| Calculate an input source CRC32.
|
|
idaman THREAD_SAFE bool ida_export | base64_encode (qstring *output, const void *input, size_t size) |
| Encode base64.
|
|
idaman THREAD_SAFE bool ida_export | base64_decode (bytevec_t *output, const char *input, size_t size) |
| Decode base64. More...
|
|
idaman THREAD_SAFE bool ida_export | replace_tabs (qstring *out, const char *str, int tabsize) |
| Convert tabulations to spaces. More...
|
|
idaman THREAD_SAFE char *ida_export | str2user (char *dst, const char *src, size_t dstsize) |
| Make a user representation.
|
|
idaman THREAD_SAFE char *ida_export | user2str (char *dst, const char *src, size_t dstsize) |
| Make an internal representation.
|
|
idaman THREAD_SAFE char ida_export | back_char (const char **p) |
| Translate char after '\'.
|
|
idaman THREAD_SAFE void ida_export | qstr2user (qstring *dst, const char *src, int nsyms=-1) |
| see str2user()
|
|
THREAD_SAFE void | qstr2user (qstring *dst, const qstring &src) |
|
idaman THREAD_SAFE void ida_export | user2qstr (qstring *dst, const qstring &src) |
| see user2str()
|
|
idaman THREAD_SAFE bool ida_export | is_valid_utf8 (const char *in) |
| Does byte sequence consist of valid UTF-8-encoded codepoints? More...
|
|
idaman THREAD_SAFE bool ida_export | utf8_utf16 (qwstring *out, const char *in, int nsyms=-1) |
| UTF-8 -> UTF-16. More...
|
|
idaman THREAD_SAFE bool ida_export | utf16_utf8 (qstring *out, const wchar16_t *in, int nsyms=-1) |
| UTF-16 -> UTF-8. More...
|
|
constexpr bool | is_lead_surrogate (wchar32_t wch) |
|
constexpr bool | is_tail_surrogate (wchar32_t wch) |
|
constexpr wchar32_t | utf16_surrogates_to_cp (wchar16_t lead_surrogate, wchar16_t tail_surrogate) |
|
idaman THREAD_SAFE bool ida_export | idb_utf8 (qstring *out, const char *in, int nsyms=-1, int flags=0) |
| IDB default C string encoding -> UTF-8. More...
|
|
idaman THREAD_SAFE bool ida_export | change_codepage (qstring *out, const char *in, int incp, int outcp) |
|
INLINE THREAD_SAFE bool | acp_utf8 (qstring *out, const char *in) |
|
THREAD_SAFE constexpr wchar16_t | utf8_wchar16 (uchar b0, uchar b1) |
|
THREAD_SAFE constexpr wchar16_t | utf8_wchar16 (uchar b0, uchar b1, uchar b2) |
|
THREAD_SAFE constexpr wchar32_t | utf8_wchar32 (uchar b0, uchar b1, uchar b2, uchar b3) |
|
idaman THREAD_SAFE wchar32_t ida_export | get_utf8_char (const char **pptr) |
| Read one UTF-8 character from string. if error, return BADCP.
|
|
idaman THREAD_SAFE bool ida_export | prev_utf8_char (wchar32_t *out_cp, const char **p, const char *begin) |
| Get the UTF-8 character from string, before 'p'. More...
|
|
idaman THREAD_SAFE size_t ida_export | skip_utf8 (const char **putf8, size_t n) |
| Advance by n codepoints into the UTF-8 buffer. More...
|
|
idaman THREAD_SAFE ssize_t ida_export | put_utf8_char (char *out, wchar32_t cp) |
| Encode the codepoint into a UTF-8 byte sequence, and add terminating zero. More...
|
|
idaman THREAD_SAFE bool ida_export | is_cp_graphical (wchar32_t cp) |
| Is the provided codepoint graphical?
|
|
idaman THREAD_SAFE size_t ida_export | qustrlen (const char *utf8) |
|
idaman THREAD_SAFE bool ida_export | qustrncpy (char *dst, const char *utf8, size_t dstsize) |
| A safer strncpy - makes sure that there is a terminating zero. More...
|
|
idaman bool ida_export | is_cvt64 () |
| is IDA converting IDB into I64?
|
|
idaman ssize_t ida_export | convert_encoding (bytevec_t *out, const char *fromcode, const char *tocode, const uchar *indata, ssize_t insize, DEFARG(int flags, 0)) |
| Convert data from encoding fromcode into tocode. More...
|
|
ssize_t | convert_encoding (bytevec_t *out, const char *fromcode, const char *tocode, const bytevec_t *indata, DEFARG(int flags, 0)) |
|
idaman THREAD_SAFE size_t ida_export | parse_command_line (qstrvec_t *args, channel_redirs_t *redirs, const char *cmdline, int flags) |
| Parse a space separated string (escaping with backslash is supported). More...
|
|
char ** | expand_argv (int *p_argc, int argc, const char *const argv[]) |
| Copy and expand command line arguments. More...
|
|
INLINE void | free_argv (int argc, char **argv) |
| Free 'argc' elements of 'argv'.
|
|
idaman bool ida_export | quote_cmdline_arg (qstring *arg) |
| Quote a command line argument if it contains escape characters. More...
|
|
idaman bool ida_export | parse_plugin_options (plugin_options_t *opts, const char *optstring) |
| Parse plugin options from IDA command line specified by -O<plugin_name>:<optstring> Note such options can be used not only for plugins, for example, currently we use them for merge (-Omerge:...) and vault server credentials (-Ovault:...) More...
|
|
idaman void ida_export | build_plugin_options (qstring *out, const plugin_options_t &opts, const char *optname=nullptr) |
| Build the plugin options, suitable for IDA command line of the form `<name1>=<value1>:...` If `optname` is provided, the `-O<optname>:` token will be prepended. More...
|
|
idaman bool ida_export | parse_dbgopts (struct instant_dbgopts_t *ido, const char *r_switch) |
| Parse the -r command line switch (for instant debugging). More...
|
|
idaman THREAD_SAFE void *ida_export | launch_process (const launch_process_params_t &lpp, qstring *errbuf=nullptr) |
| Launch the specified process in parallel. More...
|
|
idaman THREAD_SAFE int ida_export | term_process (void *handle) |
| Forcibly terminate a running process. More...
|
|
idaman THREAD_SAFE int ida_export | qwait_timed (int *status, int child, int flags, int timeout_ms) |
| Wait for state changes in a child process (UNIX only). More...
|
|
idaman THREAD_SAFE int ida_export | check_process_exit (void *handle, int *exit_code, DEFARG(int msecs,-1)) |
| Check whether process has terminated or not. More...
|
|
idaman THREAD_SAFE enum tty_control_t ida_export | is_control_tty (int fd) |
| Check if the current process is the owner of the TTY specified by 'fd' (typically an opened descriptor to /dev/tty). More...
|
|
idaman THREAD_SAFE void ida_export | qdetach_tty (void) |
| If the current terminal is the controlling terminal of the calling process, give up this controlling terminal. More...
|
|
idaman THREAD_SAFE void ida_export | qcontrol_tty (void) |
| Make the current terminal the controlling terminal of the calling process. More...
|
|
| OPAQUE_HANDLE (qthread_t) |
|
idaman THREAD_SAFE qthread_t ida_export | qthread_create (qthread_cb_t *thread_cb, void *ud) |
| Create a thread and return a thread handle.
|
|
idaman THREAD_SAFE void ida_export | qthread_free (qthread_t q) |
| Free a thread resource (does not kill the thread) (calls pthread_detach under unix)
|
|
idaman THREAD_SAFE bool ida_export | qthread_join (qthread_t q) |
| Wait a thread until it terminates.
|
|
idaman THREAD_SAFE bool ida_export | qthread_kill (qthread_t q) |
| Forcefully kill a thread (calls pthread_cancel under unix)
|
|
idaman THREAD_SAFE qthread_t ida_export | qthread_self (void) |
| Get current thread. Must call qthread_free() to free it!
|
|
idaman THREAD_SAFE bool ida_export | qthread_same (qthread_t q) |
| Is the current thread the same as 'q'?
|
|
idaman THREAD_SAFE bool ida_export | qthread_equal (qthread_t q1, qthread_t q2) |
| Are two threads equal?
|
|
idaman THREAD_SAFE bool ida_export | is_main_thread (void) |
| Are we running in the main thread?
|
|
idaman THREAD_SAFE bool ida_export | qsetenv (const char *varname, const char *value) |
| Thread safe function to work with the environment.
|
|
idaman THREAD_SAFE bool ida_export | qgetenv (const char *varname, DEFARG(qstring *buf, nullptr)) |
| Thread safe function to work with the environment. More...
|
|
| OPAQUE_HANDLE (qsemaphore_t) |
| Semaphore. More...
|
|
idaman THREAD_SAFE qsemaphore_t ida_export | qsem_create (const char *name, int init_count) |
| Create a new semaphore.
|
|
idaman THREAD_SAFE bool ida_export | qsem_free (qsemaphore_t sem) |
| Free a semaphore.
|
|
idaman THREAD_SAFE bool ida_export | qsem_post (qsemaphore_t sem) |
| Unlock a semaphore.
|
|
idaman THREAD_SAFE bool ida_export | qsem_wait (qsemaphore_t sem, int timeout_ms) |
| Lock and decrement a semaphore. timeout = -1 means block indefinitely.
|
|
| OPAQUE_HANDLE (qmutex_t) |
| Mutex.
|
|
idaman THREAD_SAFE bool ida_export | qmutex_free (qmutex_t m) |
| Free a mutex.
|
|
idaman THREAD_SAFE qmutex_t ida_export | qmutex_create (void) |
| Create a new mutex.
|
|
idaman THREAD_SAFE bool ida_export | qmutex_lock (qmutex_t m) |
| Lock a mutex.
|
|
idaman THREAD_SAFE bool ida_export | qmutex_unlock (qmutex_t m) |
| Unlock a mutex.
|
|
idaman THREAD_SAFE int ida_export | qpipe_create (qhandle_t handles[2]) |
| Create a pipe. More...
|
|
idaman THREAD_SAFE ssize_t ida_export | qpipe_read (qhandle_t handle, void *buf, size_t size) |
| Read from a pipe. More...
|
|
idaman THREAD_SAFE bool ida_export | qpipe_read_n (qhandle_t handle, bytevec_t *out_bytes, size_t n) |
| Read a specific amount of bytes from a pipe. More...
|
|
idaman THREAD_SAFE ssize_t ida_export | qpipe_write (qhandle_t handle, const void *buf, size_t size) |
| Write to a pipe. More...
|
|
idaman THREAD_SAFE int ida_export | qpipe_close (qhandle_t handle) |
| Close a pipe. More...
|
|
idaman void *ida_export | pipe_process (qhandle_t *read_handle, qhandle_t *write_handle, launch_process_params_t *lpp, qstring *errbuf=nullptr) |
| Launch a process and establish 2-way comminucation with it. More...
|
|
idaman THREAD_SAFE int ida_export | qwait_for_handles (int *idx, const qhandle_t *handles, int n, uint32 write_bitmask, int timeout_ms) |
| Wait for file/socket/pipe handles. More...
|
|
idaman THREAD_SAFE bool ida_export | get_login_name (qstring *out) |
| Get the user name for the current desktop session. More...
|
|
|
Get the length of the given string
|
THREAD_SAFE size_t idaapi | qstrlen (const char *s) |
|
THREAD_SAFE size_t idaapi | qstrlen (const uchar *s) |
|
idaman THREAD_SAFE size_t ida_export | qstrlen (const wchar16_t *s) |
|
|
Lexical comparison of strings.
- Returns
- 0 if two strings are identical > 0 if 's1' is larger than 's2' < 0 if 's2' is larger than 's1' otherwise return first nonzero comparison between chars in 's1' and 's2'
|
THREAD_SAFE int idaapi | qstrcmp (const char *s1, const char *s2) |
|
THREAD_SAFE int idaapi | qstrcmp (const uchar *s1, const uchar *s2) |
|
idaman THREAD_SAFE int ida_export | qstrcmp (const wchar16_t *s1, const wchar16_t *s2) |
|
|
Lexical comparison of string prefixes.
- Returns
- 0 if two strings are identical > 0 if 's1' is larger than 's2' < 0 if 's2' is larger than 's1' otherwise return first nonzero comparison between chars in 's1' and 's2'
|
THREAD_SAFE int idaapi | qstrncmp (const char *s1, const char *s2, size_t len) |
|
THREAD_SAFE int idaapi | qstrncmp (const uchar *s1, const uchar *s2, size_t len) |
|
idaman THREAD_SAFE int ida_export | qstrncmp (const wchar16_t *s1, const wchar16_t *s2, size_t len) |
|
|
Find a string within another string.
- Returns
- a pointer to the first occurrence of 's2' within 's1', nullptr if s2 is not found in s1
|
THREAD_SAFE const char *idaapi | qstrstr (const char *s1, const char *s2) |
|
THREAD_SAFE const uchar *idaapi | qstrstr (const uchar *s1, const uchar *s2) |
|
|
Find a character within a string.
- Returns
- a pointer to the first occurrence of 'c' within 's1', nullptr if c is not found in s1
|
THREAD_SAFE char *idaapi | qstrchr (char *s1, char c) |
|
THREAD_SAFE const char *idaapi | qstrchr (const char *s1, char c) |
|
THREAD_SAFE uchar *idaapi | qstrchr (uchar *s1, uchar c) |
|
THREAD_SAFE const uchar *idaapi | qstrchr (const uchar *s1, uchar c) |
|
idaman THREAD_SAFE const wchar16_t *ida_export | qstrchr (const wchar16_t *s1, wchar16_t c) |
|
THREAD_SAFE wchar16_t *idaapi | qstrchr (wchar16_t *s1, wchar16_t c) |
|
|
Find a last occurrence of a character within a string.
- Returns
- a pointer to the last occurrence of 'c' within 's1', nullptr if c is not found in s1
|
THREAD_SAFE const char *idaapi | qstrrchr (const char *s1, char c) |
|
THREAD_SAFE char *idaapi | qstrrchr (char *s1, char c) |
|
THREAD_SAFE const uchar *idaapi | qstrrchr (const uchar *s1, uchar c) |
|
THREAD_SAFE uchar *idaapi | qstrrchr (uchar *s1, uchar c) |
|
idaman THREAD_SAFE const wchar16_t *ida_export | qstrrchr (const wchar16_t *s1, wchar16_t c) |
|
THREAD_SAFE wchar16_t *idaapi | qstrrchr (wchar16_t *s1, wchar16_t c) |
|
|
#define | IDA_SDK_VERSION 850 |
| IDA SDK v8.5.
|
|
#define | BADMEMSIZE 0x7FFFFFFFu |
|
#define | ENUM_SIZE(t) : t |
|
#define | _CRT_DECLARE_NONSTDC_NAMES 1 |
|
#define | WIN32_LEAN_AND_MEAN |
|
#define | STL_SUPPORT_PRESENT |
|
#define | EXTERNC extern "C" |
|
#define | C_INCLUDE |
|
#define | C_INCLUDE_END } |
|
#define | INLINE inline |
|
#define | MAXSTR 1024 |
| maximum string size
|
|
#define | SMAXSTR QSTRINGIZE(MAXSTR) |
| get MAXSTR as a string
|
|
#define | NT_CDECL __cdecl |
|
#define | DEPRECATED __declspec(deprecated) |
|
#define | NORETURN __declspec(noreturn) |
|
#define | PACKED |
|
#define | PACKED_ALIGNED(al) |
|
#define | AS_STRFTIME(format_idx) |
|
#define | AS_PRINTF(format_idx, varg_idx) |
|
#define | AS_SCANF(format_idx, varg_idx) |
|
#define | WARN_UNUSED_RESULT _Check_return_ |
|
#define | GCC_DIAG_OFF(x) |
|
#define | GCC_DIAG_ON(x) |
|
#define | MSC_DIAG_OFF(x) |
|
#define | MSC_DIAG_ON(x) __pragma(warning(pop)) |
|
#define | DISABLE_ASAN |
|
#define | __MF__ 0 |
| byte sex of our platform (Most significant byte First). More...
|
|
#define | qnotused(x) (void)x |
| Macro to avoid of message 'Parameter x is never used'.
|
|
#define | NONNULL |
|
#define | QUNUSED |
|
#define | va_argi(va, type) va_arg(va, type) |
|
#define | CONST_CAST(x) const_cast<x> |
| cast a const to non-const
|
|
#define | _QSTRINGIZE(x) #x |
| return x as a string. See SMAXSTR for example
|
|
#define | QSTRINGIZE(x) _QSTRINGIZE(x) |
| see _QSTRINGIZE
|
|
#define | idaapi __stdcall |
|
#define | ida_export idaapi |
|
#define | idaman EXTERNC |
|
#define | ida_export_data __declspec(dllimport) |
|
#define | ida_module_data __declspec(dllexport) |
|
#define | ida_local |
|
#define | THREAD_SAFE |
| Functions callable from any thread are marked with this keyword.
|
|
#define | newapi |
| This keyword is used to introduce new virtual functions that do not override any existing virtual function.
|
|
#define | strtoull _strtoui64 |
|
#define | FMT_64 "I64" |
|
#define | FMT_Z "u" |
|
#define | FMT_ZX "X" |
|
#define | FMT_ZS "d" |
|
#define | SVAL_MIN INT_MIN |
|
#define | SVAL_MAX INT_MAX |
|
#define | FMT_EA "" |
|
#define | DEFARG(decl, val) decl = val |
|
#define | BADADDR ea_t(0-1) |
| this value is used for 'bad address'
|
|
#define | BADSEL sel_t(0-1) |
| 'bad selector' value
|
|
#define | BADADDR32 ea32_t(0-1ull) |
|
#define | BADADDR64 ea64_t(0-1ull) |
|
#define | qoff64_t int64 |
| file offset
|
|
#define | for if(0); else for |
| MSVC <= 1200 is not compliant to the ANSI standard.
|
|
#define | eOk 0 |
| no error
|
|
#define | eOS 1 |
| os error, see errno
|
|
#define | eDiskFull 2 |
| disk full
|
|
#define | eReadError 3 |
| read error
|
|
#define | eFileTooLarge 4 |
| file too large
|
|
#define | ZZZ msg("%s:%d\n", __FILE__, __LINE__) |
|
#define | BPT __debugbreak() |
|
#define | CASSERT(cnd) static_assert((cnd), QSTRINGIZE(cnd)) |
|
#define | INTERR(code) do { if ( under_debugger ) BPT; interr(code); } while(1) |
|
#define | QASSERT(code, cond) do if ( !(cond) ) INTERR(code); while (0) |
| run time assertion
|
|
#define | QBUFCHECK(buf, size, src) ida_fill_buffer(buf, size, src, __FILE__, __LINE__) |
| run time assertion
|
|
#define | TB_QASSERT(Code, Expr) |
|
#define | TB_INTERR(Code) |
|
#define | TB_CCHECK(expr) if ( !(expr) ) msg("Coherency check failed: " #expr "\n") |
|
#define | TB_INTERR_OR_RETURN(code, ...) return __VA_ARGS__ |
|
#define | INTERR_EXC_FMT |
|
#define | qnew(t) ((t*)qalloc(sizeof(t))) |
| create a new object in memory
|
|
#define | qnewarray(t, n) use_qalloc_array |
|
#define | qnumber(array) _countof(array) |
|
#define | qoffsetof offsetof |
|
#define | va_copy(dst, src) dst = src |
|
#define | set_vva(va2, vp) va_copy(va2, va_arg(vp, va_list)) |
|
#define | NULL_VA_LIST() nullptr |
|
#define | strnicmp _strnicmp |
|
#define | stricmp _stricmp |
|
#define | strcpy dont_use_strcpy |
| use qstrncpy()
|
|
#define | stpcpy dont_use_stpcpy |
| use qstpncpy()
|
|
#define | strncpy dont_use_strncpy |
| use qstrncpy()
|
|
#define | strcat dont_use_strcat |
| use qstrncat()
|
|
#define | strncat dont_use_strncat |
| use qstrncat()
|
|
#define | gets dont_use_gets |
| use qfgets()
|
|
#define | sprintf dont_use_sprintf |
| use qsnprintf()
|
|
#define | snprintf dont_use_snprintf |
| use qsnprintf()
|
|
#define | wsprintfA dont_use_wsprintf |
| use qsnprintf()
|
|
#define | strcmpi dont_use_strcmpi |
| use stricmp()
|
|
#define | strncmpi dont_use_strncmpi |
| use strnicmp()
|
|
#define | getenv dont_use_getenv |
| use qgetenv()
|
|
#define | setenv dont_use_setenv |
| use qsetenv()
|
|
#define | putenv dont_use_putenv |
| use qsetenv()
|
|
#define | strtok dont_use_strrok |
| use qstrtok()
|
|
#define | strlwr dont_use_strlwr |
| use qstrlwr()
|
|
#define | strupr dont_use_strupr |
| use qstrupr()
|
|
#define | waitid dont_use_waitid |
| use qwait()
|
|
#define | waitpid dont_use_waitpid |
| use qwait()
|
|
#define | wait dont_use_wait |
| use qwait()
|
|
#define | QMAXPATH 260 |
|
#define | QMAXFILE 260 |
|
#define | DELIMITER ";" |
| Delimiter of directory lists. More...
|
|
#define | WPM_EXPLICIT_DOT 0x01 |
|
#define | SEEK_SET 0 |
| beginning of file
|
|
#define | SEEK_CUR 1 |
| current position of the file *
|
|
#define | SEEK_END 2 |
| end of file *
|
|
#define | qmin(a, b) ((a) < (b)? (a): (b)) |
| universal min
|
|
#define | qmax(a, b) ((a) > (b)? (a): (b)) |
| universal max
|
|
#define | OPERATOR_NEW(type, count) new type[count] |
|
#define | MC2(c1, c2) ushort(((c2)<<8)|c1) |
| We cannot use multi-character constants because they are not portable - use this macro instead.
|
|
#define | MC3(c1, c2, c3) uint32(((((c3)<<8)|(c2))<<8)|c1) |
| We cannot use multi-character constants because they are not portable - use this macro instead. More...
|
|
#define | MC4(c1, c2, c3, c4) uint32(((((((c4)<<8)|(c3))<<8)|(c2))<<8)|c1) |
| We cannot use multi-character constants because they are not portable - use this macro instead. More...
|
|
#define | read4bytes(h, res, mf) readbytes(h, res, 4, mf) |
| see readbytes()
|
|
#define | write2bytes(h, l, mf) writebytes(h, l, 2, mf) |
| see writebytes()
|
|
#define | write4bytes(h, l, mf) writebytes(h, l, 4, mf) |
| see writebytes()
|
|
#define | swapea swap32 |
|
#define | qhtons(x) swap16(x) |
|
#define | qntohs(x) swap16(x) |
|
#define | qhtonl(x) swap32(x) |
|
#define | qntohl(x) swap32(x) |
|
#define | PLACEMENT_DELETE void operator delete(void *, void *) {} |
|
#define | DEFINE_MEMORY_ALLOCATION_FUNCS() |
|
#define | DECLARE_COMPARISON_OPERATORS(type) |
| Macro to declare standard inline comparison operators. More...
|
|
#define | DECLARE_COMPARISONS(type) |
| Macro to declare comparisons for our classes. More...
|
|
#define | SSF_DROP_EMPTY 0x1 |
| drop empty parts
|
|
#define | streq(s1, s2) (::qstrcmp((s1), (s2)) == 0) |
| convenient check for string equality
|
|
#define | strneq(s1, s2, count) (::qstrncmp((s1), (s2), (count)) == 0) |
| see streq
|
|
#define | strieq(s1, s2) (stricmp((s1), (s2)) == 0) |
| see streq
|
|
#define | strnieq(s1, s2, count) (strnicmp((s1), (s2), (count)) == 0) |
| see streq
|
|
#define | RELOBJ_MASK 0xF |
| the first byte describes the relocation entry types
|
|
#define | RELSIZE_1 0 |
| 8-bit relocations
|
|
#define | RELSIZE_2 1 |
| 16-bit relocations
|
|
#define | RELSIZE_4 2 |
| 32-bit relocations
|
|
#define | RELSIZE_8 3 |
| 64-bit relocations
|
|
#define | RELSIZE_CUST 15 |
| custom relocations, should be handled internally
|
|
#define | RELOBJ_CNT 0x80 |
| counter present (not used yet)
|
|
#define | QLIST_DEFINED |
| signal that the qlist class has been defined
|
|
#define | DEFINE_LIST_ITERATOR(iter, constness, cstr) |
| Used for defining the 'iterator' and 'const_iterator' classes for qlist.
|
|
#define | DEFINE_REVERSE_ITERATOR(riter, iter) |
|
#define | SCALAR_TYPE(n) class T, typename std::enable_if<std::is_scalar<T>::value && sizeof(T) == n, int>::type = 0 |
|
#define | DECLARE_MEMORY_DESERIALIZER(name) |
|
#define | SCALAR_TYPE(n) class T, typename std::enable_if<std::is_scalar<T>::value && sizeof(T) == n, int>::type = 0 |
|
#define | DECLARE_MEMORY_SERIALIZER(name) using memory_serializer_t::pack; \ |
|
#define | COMPARE_POINTERS2(ptr, cmp) |
|
#define | COMPARE_POINTERS(ptr) COMPARE_POINTERS2(ptr, ::compare) |
|
#define | COMPARE_FIELDS(fld) |
|
#define | COMPARE_FIELDS_REV(fld) |
|
#define | DECLARE_UNCOPYABLE(T) T &operator=(const T &); T(const T &); |
| Declare class as uncopyable. More...
|
|
#define | IDBDEC_ESCAPE 0x00000001 |
| convert non-printable characters to C escapes (
, \xNN, \uNNNN)
|
|
#define | CP_ACP 0 |
|
#define | CP_OEM 1 |
|
#define | CP_UTF8 65001 |
|
#define | BADCP wchar32_t(-1) |
|
#define | CP_BOM 0xFEFF |
|
#define | UTF8_BOM "\xEF\xBB\xBF" |
|
#define | UTF8_BOM_SZ (sizeof(UTF8_BOM) - 1) |
|
#define | UTF16LE_BOM "\xFF\xFE" |
|
#define | UTF16BE_BOM "\xFE\xFF" |
|
#define | UTF16_BOM_SZ (sizeof(UTF16LE_BOM) - 1) |
|
#define | UTF32LE_BOM "\xFF\xFE\x00\x00" |
|
#define | UTF32BE_BOM "\x00\x00\xFE\xFF" |
|
#define | UTF32_BOM_SZ (sizeof(UTF32LE_BOM) - 1) |
|
#define | CP_ELLIPSIS 0x2026 |
|
#define | UTF8_ELLIPSIS "\xE2\x80\xA6" |
|
#define | UTF8_ELLIPSIS_SZ (sizeof(UTF8_ELLIPSIS) - 1) |
|
#define | CP_REPLCHAR 0xFFFD |
|
#define | UTF8_REPLCHAR "\xEF\xBF\xBD" |
|
#define | UTF8_REPLCHAR_SZ (sizeof(UTF8_REPLCHAR) - 1) |
|
#define | MAX_UTF8_SEQ_LEN (6 + 1 + 1) |
|
#define | CEF_RETERR 0x1 |
|
#define | ENC_WIN1252 "windows-1252" |
|
#define | ENC_UTF8 "UTF-8" |
|
#define | ENC_MUTF8 "MUTF-8" |
|
#define | ENC_UTF16 "UTF-16" |
|
#define | ENC_UTF16LE "UTF-16LE" |
|
#define | ENC_UTF16BE "UTF-16BE" |
|
#define | ENC_UTF32 "UTF-32" |
|
#define | ENC_UTF32LE "UTF-32LE" |
|
#define | ENC_UTF32BE "UTF-32BE" |
|
#define | CP_UTF16 1200 |
| UTF-16 codepage.
|
|
#define | INVALID_FILE_ATTRIBUTES ((DWORD)-1) |
| old Visual C++ compilers were not defining this
|
|
#define | BELOW_NORMAL_PRIORITY_CLASS 0x00004000 |
| old Visual C++ compilers were not defining this More...
|
|
#define | SUBSTCHAR '_' |
| default char, used if a char cannot be represented in a codepage
|
|
#define | DEFCOLOR bgcolor_t(-1) |
| default color (used in function, segment definitions)
|
|
#define | IOREDIR_INPUT 0x01 |
| input redirection
|
|
#define | IOREDIR_OUTPUT 0x02 |
| output redirection
|
|
#define | IOREDIR_APPEND 0x04 |
| append, do not overwrite the output file
|
|
#define | IOREDIR_QUOTED 0x08 |
| the file name was quoted
|
|
#define | DEFINE_CLIOPTS_T_HELPERS(decl) |
|
#define | DEFINE_PLUGIN_OPTION_T_HELPERS(decl) decl bool ida_export plugin_option_t_get_bool(const plugin_option_t *, bool *, const char *, bool); |
|
#define | LP_NEW_CONSOLE 0x0001 |
| create new console (only ms windows)
|
|
#define | LP_TRACE 0x0002 |
| debug: unix: ptrace(TRACEME), windows: DEBUG_PROCESS
|
|
#define | LP_PATH_WITH_ARGS 0x0004 |
| 'args' contains executable path too
|
|
#define | LP_USE_SHELL 0x0008 |
| use shell to launch the command. More...
|
|
#define | LP_LAUNCH_32_BIT 0x0010 |
| prefer to launch 32-bit part of file (only mac)
|
|
#define | LP_LAUNCH_64_BIT 0x0020 |
| prefer to launch 64-bit part of file (only mac); only one of LP_LAUNCH_*_BIT bits can be specified
|
|
#define | LP_NO_ASLR 0x0040 |
| disable ASLR (mac and linux)
|
|
#define | LP_DETACH_TTY 0x0080 |
| detach the current tty (unix)
|
|
#define | LP_HIDE_WINDOW 0x0100 |
| tries to hide new window on startup (only windows)
|
|
#define | LP_SUSPENDED 0x0200 |
| suspends the process on startup (only mac)
|
|
#define | LP_DETACHED 0x0400 |
| no need to reap the child (this bit is ignored on windows)
|
|
#define | LP_REPLACE_ENV 0x0800 |
| completely replace env for process
|
|
#define | OPAQUE_HANDLE(n) typedef struct __ ## n {} *n |
| Thread opaque handle.
|
|
|
Shut up Visual Studio (VS deprecated posix names but there seems to be no good reason for that)
|
#define | chdir _chdir |
|
#define | fileno _fileno |
|
#define | getcwd _getcwd |
|
#define | memicmp _memicmp |
|
#define | F_OK 0 |
|
#define | W_OK 2 |
|
#define | R_OK 4 |
|
|
In the following macros, 'buf' must be always less than 'end'.
When we run up to the end, we put a 0 there and don't increase buf anymore
Append a character to the buffer checking the buffer size
|
#define | APPCHAR(buf, end, chr) |
|
#define | APPZERO(buf, end) |
| Put a zero byte at buffer. More...
|
|
#define | APPEND(buf, end, name) |
| Append a string to the buffer checking the buffer size. More...
|
|