41#ifdef CONF_FAMILY_UNIX
45#ifdef CONF_PLATFORM_LINUX
46#include <netinet/in.h>
47#include <sys/socket.h>
50#if __cplusplus >= 201703L
51#define MAYBE_UNUSED [[maybe_unused]]
52#elif defined(__GNUC__)
53#define MAYBE_UNUSED __attribute__((unused))
76#define dbg_assert(test, msg) dbg_assert_imp(__FILE__, __LINE__, test, msg)
77void dbg_assert_imp(
const char *filename,
int line,
bool test,
const char *msg);
79#ifdef __clang_analyzer__
82#define dbg_assert(test, msg) assert(test)
86#define GNUC_ATTRIBUTE(x) __attribute__(x)
88#define GNUC_ATTRIBUTE(x)
110#if defined(__cplusplus)
131void dbg_msg(
const char *sys,
const char *fmt, ...)
152void mem_copy(
void *dest, const
void *source,
size_t size);
167void mem_move(
void *dest, const
void *source,
size_t size);
180 static_assert((std::is_trivially_constructible<T>::value && std::is_trivially_destructible<T>::value) || std::is_fundamental<T>::value);
181 memset(block, 0, size);
197int mem_comp(
const void *a,
const void *b,
size_t size);
629void *
thread_init(
void (*threadfunc)(
void *),
void *user,
const char *name);
674#if defined(CONF_FAMILY_WINDOWS)
676#elif defined(CONF_PLATFORM_MACOS)
677#include <semaphore.h>
679#elif defined(CONF_FAMILY_UNIX)
680#include <semaphore.h>
683#error not implemented on this platform
802#ifdef CONF_FAMILY_UNIX
1077#if defined(CONF_FAMILY_UNIX)
1125#elif defined(CONF_FAMILY_WINDOWS)
1134std::string windows_format_system_message(
unsigned long error);
1156void str_append(
char *dst,
const char *src,
int dst_size);
1189int str_copy(
char *dst,
const char *src,
int dst_size);
1221void str_utf8_truncate(
char *dst,
int dst_size,
const char *src,
int truncation_len);
1237void str_truncate(
char *dst,
int dst_size,
const char *src,
int truncation_len);
1266int str_format_v(
char *buffer,
int buffer_size,
const char *format, va_list args)
1285int str_format(
char *buffer,
int buffer_size,
const char *format, ...)
1288#if !defined(CONF_DEBUG)
1291template<
typename... Args>
1294 static_assert(
sizeof...(args) > 0,
"Use str_copy instead of str_format without format arguments");
1295 return str_format(buffer, buffer_size, format, args...);
1301 if(strcmp(format,
"%d") == 0)
1307 return str_format(buffer, buffer_size, format, val);
1311#define str_format str_format_opt
1477int str_comp(
const char *a,
const char *b);
1494int str_comp_num(
const char *a,
const char *b,
int num);
1576const char *
str_endswith(
const char *str,
const char *suffix);
1664const char *
str_find(
const char *haystack,
const char *needle);
1696const char *
str_rchr(
const char *haystack,
char needle);
1724void str_hex(
char *dst,
int dst_size,
const void *data,
int data_size);
1740void str_hex_cstyle(
char *dst,
int dst_size,
const void *data,
int data_size,
int bytes_per_line = 12);
1775void str_base64(
char *dst,
int dst_size,
const void *data,
int data_size);
1810void str_timestamp_ex(time_t time,
char *buffer,
int buffer_size,
const char *format)
1828#define FORMAT_TIME "%H:%M:%S"
1829#define FORMAT_SPACE "%Y-%m-%d %H:%M:%S"
1830#define FORMAT_NOSPACE "%Y-%m-%d_%H-%M-%S"
1859int str_time(int64_t centisecs,
int format,
char *buffer,
int buffer_size);
1860int str_time_float(
float secs,
int format,
char *buffer,
int buffer_size);
1872void str_escape(
char **dst,
const char *src,
const char *end);
2037char *
fs_getcwd(
char *buffer,
int buffer_size);
2070void fs_split_file_extension(
const char *filename,
char *name,
size_t name_size,
char *extension =
nullptr,
size_t extension_size = 0);
2111int fs_rename(
const char *oldname,
const char *newname);
2127int fs_file_time(
const char *name, time_t *created, time_t *modified);
2179void swap_endian(
void *data,
unsigned elem_size,
unsigned num);
2192bool str_toint(
const char *str,
int *out);
2299const char *
str_utf8_find_nocase(
const char *haystack,
const char *needle,
const char **end =
nullptr);
2468void str_utf8_stats(
const char *str,
size_t max_size,
size_t max_count,
size_t *size,
size_t *count);
2512const char *
str_next_token(
const char *str,
const char *delim,
char *buffer,
int buffer_size);
2527int str_in_list(
const char *list,
const char *delim,
const char *needle);
2592#if defined(CONF_FAMILY_WINDOWS)
2619#if !defined(CONF_PLATFORM_ANDROID)
2816#if defined(CONF_EXCEPTION_HANDLING)
2827void init_exception_handler();
2836void set_exception_handler_log_file(
const char *log_file_path);
2874#if defined(CONF_FAMILY_WINDOWS)
2888std::wstring windows_utf8_to_wide(
const char *str);
2903std::optional<std::string> windows_wide_to_utf8(
const wchar_t *wide_str);
2915class CWindowsComLifecycle
2918 CWindowsComLifecycle(
bool HasWindow);
2919 ~CWindowsComLifecycle();
2935bool shell_register_protocol(
const char *protocol_name,
const char *executable,
bool *updated);
2952bool shell_register_extension(
const char *extension,
const char *description,
const char *executable_name,
const char *executable,
bool *updated);
2967bool shell_register_application(
const char *name,
const char *executable,
bool *updated);
2983bool shell_unregister_class(
const char *shell_class,
bool *updated);
2997bool shell_unregister_application(
const char *executable,
bool *updated);
3012 size_t operator()(
const NETADDR &Addr)
const noexcept;
Definition: system.h:2857
~CCmdlineFix()
Definition: system.h:2868
int m_Argc
Definition: system.h:2858
const char ** m_ppArgv
Definition: system.h:2859
CCmdlineFix(int *pArgc, const char ***pppArgv)
Definition: system.h:2862
void dbg_break()
Definition: system.cpp:150
bool dbg_assert_has_failed()
Definition: system.cpp:125
void dbg_msg(const char *sys, const char *fmt,...)
Definition: system.cpp:164
void aio_write_newline_unlocked(ASYNCIO *aio)
Definition: system.cpp:741
IOHANDLE io_current_exe()
Definition: system.cpp:452
void aio_wait(ASYNCIO *aio)
Definition: system.cpp:772
void aio_write_unlocked(ASYNCIO *aio, const void *buffer, unsigned size)
Definition: system.cpp:684
int io_flush(IOHANDLE io)
Definition: system.cpp:414
ESeekOrigin
Definition: system.h:246
int64_t io_tell(IOHANDLE io)
Definition: system.cpp:372
IOHANDLE io_stderr()
Definition: system.cpp:447
IOHANDLE io_open(const char *filename, int flags)
Definition: system.cpp:202
int io_close(IOHANDLE io)
Definition: system.cpp:409
char * io_read_all_str(IOHANDLE io)
Definition: system.cpp:326
void aio_write(ASYNCIO *aio, const void *buffer, unsigned size)
Definition: system.cpp:734
void aio_write_newline(ASYNCIO *aio)
Definition: system.cpp:750
int io_skip(IOHANDLE io, int64_t size)
Definition: system.cpp:342
int aio_error(ASYNCIO *aio)
Definition: system.cpp:757
void aio_free(ASYNCIO *aio)
Definition: system.cpp:788
unsigned io_write(IOHANDLE io, const void *buffer, unsigned size)
Definition: system.cpp:395
bool io_write_newline(IOHANDLE io)
Definition: system.cpp:400
bool io_read_all(IOHANDLE io, void **result, unsigned *result_len)
Definition: system.cpp:269
void aio_lock(ASYNCIO *aio)
Definition: system.cpp:673
void aio_close(ASYNCIO *aio)
Definition: system.cpp:763
int io_sync(IOHANDLE io)
Definition: system.cpp:419
int io_seek(IOHANDLE io, int64_t offset, ESeekOrigin origin)
Definition: system.cpp:347
IOHANDLE io_stdin()
Definition: system.cpp:437
int io_error(IOHANDLE io)
Definition: system.cpp:432
IOHANDLE io_stdout()
Definition: system.cpp:442
ASYNCIO * aio_new(IOHANDLE io)
Definition: system.cpp:616
void aio_unlock(ASYNCIO *aio)
Definition: system.cpp:678
int64_t io_length(IOHANDLE io)
Definition: system.cpp:381
unsigned io_read(IOHANDLE io, void *buffer, unsigned size)
Definition: system.cpp:264
@ IOSEEK_END
Definition: system.h:264
@ IOSEEK_CUR
Definition: system.h:258
@ IOSEEK_START
Definition: system.h:252
@ IOFLAG_APPEND
Definition: system.h:239
@ IOFLAG_WRITE
Definition: system.h:233
@ IOFLAG_READ
Definition: system.h:227
void fs_listdir(const char *dir, FS_LISTDIR_CALLBACK cb, int type, void *user)
Definition: system.cpp:2146
const char * fs_filename(const char *path)
Definition: system.cpp:2463
void fs_split_file_extension(const char *filename, char *name, size_t name_size, char *extension=nullptr, size_t extension_size=0)
Definition: system.cpp:2473
int fs_is_relative_path(const char *path)
Definition: system.cpp:2418
int fs_is_file(const char *path)
Definition: system.cpp:2390
int fs_removedir(const char *path)
Definition: system.cpp:2376
int fs_parent_dir(char *path)
Definition: system.cpp:2496
void fs_listdir_fileinfo(const char *dir, FS_LISTDIR_CALLBACK_FILEINFO cb, int type, void *user)
Definition: system.cpp:2198
char * fs_getcwd(char *buffer, int buffer_size)
Definition: system.cpp:2438
int fs_is_dir(const char *path)
Definition: system.cpp:2404
int fs_file_time(const char *name, time_t *created, time_t *modified)
Definition: system.cpp:2537
int fs_makedir_rec_for(const char *path)
Definition: system.cpp:2332
int fs_storage_path(const char *appname, char *path, int max)
Definition: system.cpp:2265
int fs_chdir(const char *path)
Definition: system.cpp:2428
int fs_remove(const char *filename)
Definition: system.cpp:2513
int fs_rename(const char *oldname, const char *newname)
Definition: system.cpp:2523
int fs_makedir(const char *path)
Definition: system.cpp:2353
void mem_zero(T *block, size_t size)
Definition: system.h:178
void mem_copy(void *dest, const void *source, size_t size)
Definition: system.cpp:174
bool mem_has_null(const void *block, size_t size)
Definition: system.cpp:189
void mem_move(void *dest, const void *source, size_t size)
Definition: system.cpp:179
int mem_comp(const void *a, const void *b, size_t size)
Definition: system.cpp:184
int UNIXSOCKET
Definition: system.h:806
bool net_addr_str(const NETADDR *addr, char *string, int max_length, int add_port)
Definition: system.cpp:1147
int net_addr_comp_noport(const NETADDR *a, const NETADDR *b)
Definition: system.cpp:1072
void net_init()
Definition: system.cpp:2098
int net_addr_comp(const NETADDR *a, const NETADDR *b)
Definition: system.cpp:1062
struct sockaddr_un UNIXSOCKETADDR
Definition: system.h:810
int net_tcp_close(NETSOCKET sock)
Definition: system.cpp:2075
int net_tcp_listen(NETSOCKET sock, int backlog)
Definition: system.cpp:1960
int net_tcp_accept(NETSOCKET sock, NETSOCKET *new_sock, NETADDR *addr)
Definition: system.cpp:1970
int net_tcp_connect(NETSOCKET sock, const NETADDR *addr)
Definition: system.cpp:2017
NETSOCKET net_tcp_create(NETADDR bindaddr)
Definition: system.cpp:1883
int net_tcp_send(NETSOCKET sock, const void *data, int size)
Definition: system.cpp:2051
int net_tcp_recv(NETSOCKET sock, void *data, int maxsize)
Definition: system.cpp:2063
int net_udp_send(NETSOCKET sock, const NETADDR *addr, const void *data, int size)
Definition: system.cpp:1675
int net_udp_close(NETSOCKET sock)
Definition: system.cpp:1878
int net_unix_send(UNIXSOCKET sock, UNIXSOCKETADDR *addr, void *data, int size)
Definition: system.cpp:2112
void net_unix_set_addr(UNIXSOCKETADDR *addr, const char *path)
Definition: system.cpp:2117
UNIXSOCKET net_unix_create_unnamed()
Definition: system.cpp:2107
void net_unix_close(UNIXSOCKET sock)
Definition: system.cpp:2124
void secure_random_password(char *buffer, unsigned length, unsigned pw_length)
Definition: system.cpp:4431
void generate_password(char *buffer, unsigned length, const unsigned short *random, unsigned random_length)
Definition: system.cpp:4411
int secure_rand()
Definition: system.cpp:4471
int secure_random_init()
Definition: system.cpp:4352
int secure_random_uninit()
Definition: system.cpp:4382
void secure_random_fill(void *bytes, unsigned length)
Definition: system.cpp:4447
int secure_rand_below(int below)
Definition: system.cpp:4490
void sphore_signal(SEMAPHORE *sem)
Definition: system.cpp:955
void sphore_destroy(SEMAPHORE *sem)
Definition: system.cpp:959
void sphore_init(SEMAPHORE *sem)
Definition: system.cpp:942
void sphore_wait(SEMAPHORE *sem)
Definition: system.cpp:946
bool os_version_str(char *version, size_t length)
Definition: system.cpp:4506
int kill_process(PROCESS process)
Definition: system.cpp:4244
bool is_process_alive(PROCESS process)
Definition: system.cpp:4264
EShellExecuteWindowState
Definition: system.h:2629
int open_link(const char *link)
Definition: system.cpp:4277
constexpr PROCESS INVALID_PROCESS
Definition: system.h:2617
void cmdline_free(int argc, const char **argv)
Definition: system.cpp:4186
void os_locale_str(char *locale, size_t length)
Definition: system.cpp:4585
void cmdline_fix(int *argc, const char ***argv)
Definition: system.cpp:4148
PROCESS shell_execute(const char *file, EShellExecuteWindowState window_state)
Definition: system.cpp:4195
int open_file(const char *path)
Definition: system.cpp:4317
int pid()
Definition: system.cpp:4139
pid_t PROCESS
Definition: system.h:2611
const char * str_rchr(const char *haystack, char needle)
Definition: system.cpp:3238
char * str_skip_to_whitespace(char *str)
Definition: system.cpp:2927
int str_length(const char *str)
Definition: system.cpp:2795
void str_sanitize(char *str)
Definition: system.cpp:2873
const char * str_startswith(const char *str, const char *prefix)
Definition: system.cpp:3029
bool str_has_cc(const char *str)
Definition: system.cpp:2846
void str_sanitize_cc(char *str)
Definition: system.cpp:2861
const char * str_skip_whitespaces_const(const char *str)
Definition: system.cpp:2948
const char * str_skip_to_whitespace_const(const char *str)
Definition: system.cpp:2934
int str_format_v(char *buffer, int buffer_size, const char *format, va_list args)
Definition: system.cpp:2800
int str_comp_num(const char *a, const char *b, int num)
Definition: system.cpp:2979
void str_utf8_truncate(char *dst, int dst_size, const char *src, int truncation_len)
Definition: system.cpp:2768
int str_comp_filenames(const char *a, const char *b)
Definition: system.cpp:2984
int str_comp_nocase(const char *a, const char *b)
Definition: system.cpp:2956
void str_truncate(char *dst, int dst_size, const char *src, int truncation_len)
Definition: system.cpp:2785
bool str_delimiters_around_offset(const char *haystay, const char *delim, int offset, int *start, int *end)
Definition: system.cpp:3206
int str_countchr(const char *haystack, char needle)
Definition: system.cpp:3243
int str_comp(const char *a, const char *b)
Definition: system.cpp:2974
void str_append(char *dst, const char *src, int dst_size)
Definition: system.cpp:2744
void str_clean_whitespaces(char *str)
Definition: system.cpp:2896
int str_copy(char *dst, const char *src, int dst_size)
Definition: system.cpp:2761
char * str_skip_whitespaces(char *str)
Definition: system.cpp:2941
int str_comp_nocase_num(const char *a, const char *b, int num)
Definition: system.cpp:2965
int str_utf8_dist_buffer(const char *a, const char *b, int *buf, int buf_len)
Definition: system.cpp:3148
int str_isspace(char c)
Definition: system.cpp:3623
const char * str_trim_words(const char *str, int words)
Definition: system.cpp:2833
void thread_wait(void *thread)
Definition: system.cpp:850
void * thread_init(void(*threadfunc)(void *), void *user, const char *name)
Definition: system.cpp:824
void thread_yield()
Definition: system.cpp:862
void thread_init_and_detach(void(*threadfunc)(void *), void *user, const char *name)
Definition: system.cpp:884
void thread_detach(void *thread)
Definition: system.cpp:873
std::chrono::nanoseconds time_get_nanoseconds()
Definition: system.cpp:4701
ETimeSeason
Definition: system.h:770
void set_new_tick()
Definition: system.cpp:967
int64_t time_freq()
Definition: system.cpp:994
int time_houroftheday()
Definition: system.cpp:2659
int64_t time_timestamp()
Definition: system.cpp:2641
ETimeSeason time_season()
Definition: system.cpp:2697
int64_t time_get()
Definition: system.cpp:982
int64_t time_get_impl()
Definition: system.cpp:977
@ SEASON_AUTUMN
Definition: system.h:773
@ SEASON_WINTER
Definition: system.h:774
@ SEASON_SPRING
Definition: system.h:771
@ SEASON_HALLOWEEN
Definition: system.h:776
@ SEASON_XMAS
Definition: system.h:777
@ SEASON_EASTER
Definition: system.h:775
@ SEASON_SUMMER
Definition: system.h:772
@ SEASON_NEWYEAR
Definition: system.h:778
void * IOHANDLE
Definition: logger.h:11
Definition: system.cpp:493
void * thread
Definition: system.cpp:497
unsigned char * buffer
Definition: system.cpp:499
IOHANDLE io
Definition: system.cpp:495
Definition: system.cpp:110
Definition: system.h:2182
uint64_t recv_packets
Definition: system.h:2185
uint64_t recv_bytes
Definition: system.h:2186
uint64_t sent_packets
Definition: system.h:2183
uint64_t sent_bytes
Definition: system.h:2184
void str_utf8_trim_right(char *param)
Definition: system.cpp:3809
void str_hex_cstyle(char *dst, int dst_size, const void *data, int data_size, int bytes_per_line=12)
Definition: system.cpp:3270
int str_utf8_comp_nocase(const char *a, const char *b)
Definition: system.cpp:3711
void swap_endian(void *data, unsigned elem_size, unsigned num)
Definition: system.cpp:2563
size_t str_utf8_offset_chars_to_bytes(const char *str, size_t char_offset)
Definition: system.cpp:4057
void str_utf8_copy_num(char *dst, const char *src, int dst_size, int num)
Definition: system.cpp:4004
NETSOCKET net_udp_create(NETADDR bindaddr)
Definition: system.cpp:1577
void dbg_assert_set_handler(DBG_ASSERT_HANDLER handler)
Definition: system.cpp:159
int str_isallnum(const char *str)
Definition: system.cpp:3640
int str_utf8_forward(const char *str, int cursor)
Definition: system.cpp:3869
const char * str_next_token(const char *str, const char *delim, char *buffer, int buffer_size)
Definition: system.cpp:4106
int str_utf8_decode(const char **ptr)
Definition: system.cpp:3924
unsigned long str_toulong_base(const char *str, int base)
Definition: system.cpp:3684
const char * str_find_nocase(const char *haystack, const char *needle)
Definition: system.cpp:3168
int net_would_block()
Definition: system.cpp:2089
void str_base64(char *dst, int dst_size, const void *data, int data_size)
Definition: system.cpp:3362
int net_host_lookup(const char *hostname, NETADDR *addr, int types)
Definition: system.cpp:1252
int str_utf8_encode(char *ptr, int chr)
Definition: system.cpp:3879
int str_utf8_dist(const char *a, const char *b)
Definition: system.cpp:3092
int str_toint_base(const char *str, int base)
Definition: system.cpp:3679
int str_utf8_isstart(char c)
Definition: system.cpp:3834
bool timestamp_from_str(const char *string, const char *format, time_t *timestamp)
Definition: system.cpp:3531
void str_escape(char **dst, const char *src, const char *end)
Definition: system.cpp:3602
int net_addr_from_url(NETADDR *addr, const char *string, char *host_buf, size_t host_buf_size)
Definition: system.cpp:1326
int str_utf32_dist_buffer(const int *a, int a_len, const int *b, int b_len, int *buf, int buf_len)
Definition: system.cpp:3112
const char * str_utf8_skip_whitespaces(const char *str)
Definition: system.cpp:3789
void str_sanitize_filename(char *str)
Definition: system.cpp:2884
int net_tcp_connect_non_blocking(NETSOCKET sock, NETADDR bindaddr)
Definition: system.cpp:2040
std::function< void(const char *message)> DBG_ASSERT_HANDLER
Definition: system.h:116
int net_set_non_blocking(NETSOCKET sock)
Definition: system.cpp:1950
int str_in_list(const char *list, const char *delim, const char *needle)
Definition: system.cpp:4092
int str_utf8_comp_confusable(const char *str1, const char *str2)
Definition: confusables.cpp:83
int net_socket_type(NETSOCKET sock)
Definition: system.cpp:1572
void str_timestamp(char *buffer, int buffer_size)
Definition: system.cpp:3526
void uint_to_bytes_be(unsigned char *bytes, unsigned value)
Definition: system.cpp:4131
int str_format_int(char *buffer, size_t buffer_size, int value)
Definition: system.cpp:2812
int str_base64_decode(void *dst, int dst_size, const char *data)
Definition: system.cpp:3439
@ TIME_SECS_CENTISECS
Definition: system.h:1839
@ TIME_HOURS_CENTISECS
Definition: system.h:1837
@ TIME_DAYS
Definition: system.h:1834
@ TIME_MINS
Definition: system.h:1836
@ TIME_HOURS
Definition: system.h:1835
@ TIME_MINS_CENTISECS
Definition: system.h:1838
int str_time_float(float secs, int format, char *buffer, int buffer_size)
Definition: system.cpp:3597
const NETADDR NETADDR_ZEROED
Definition: system.cpp:1002
#define GNUC_ATTRIBUTE(x)
Definition: system.h:88
int net_errno()
Definition: system.cpp:2080
int str_toint(const char *str)
Definition: system.cpp:3662
void str_utf8_stats(const char *str, size_t max_size, size_t max_count, size_t *size, size_t *count)
Definition: system.cpp:4022
int str_format_opt(char *buffer, int buffer_size, const char *format, Args... args)
Definition: system.h:1292
int str_hex_decode(void *dst, int dst_size, const char *src)
Definition: system.cpp:3345
bool str_isnum(char c)
Definition: system.cpp:3635
void str_timestamp_format(char *buffer, int buffer_size, const char *format)
Definition: system.cpp:3519
void str_timestamp_ex(time_t time, char *buffer, int buffer_size, const char *format)
Definition: system.cpp:3512
float str_tofloat(const char *str)
Definition: system.cpp:3694
void str_hex(char *dst, int dst_size, const void *data, int data_size)
Definition: system.cpp:3255
void net_stats(NETSTATS *stats)
Definition: system.cpp:3618
unsigned str_quickhash(const char *str)
Definition: system.cpp:4070
int net_socket_read_wait(NETSOCKET sock, int time)
Definition: system.cpp:2589
void dbg_assert_imp(const char *filename, int line, bool test, const char *msg)
Definition: system.cpp:130
int net_set_blocking(NETSOCKET sock)
Definition: system.cpp:1955
sem_t SEMAPHORE
Definition: system.h:681
size_t str_utf8_offset_bytes_to_chars(const char *str, size_t byte_offset)
Definition: system.cpp:4042
int net_addr_from_str(NETADDR *addr, const char *string)
Definition: system.cpp:1375
int str_utf8_check(const char *str)
Definition: system.cpp:3991
const char * str_utf8_find_nocase(const char *haystack, const char *needle, const char **end=nullptr)
Definition: system.cpp:3751
#define str_format
Definition: system.h:1311
int str_isallnum_hex(const char *str)
Definition: system.cpp:3651
int str_utf8_isspace(int code)
Definition: system.cpp:3778
int str_time(int64_t centisecs, int format, char *buffer, int buffer_size)
Definition: system.cpp:3550
const char * str_startswith_nocase(const char *str, const char *prefix)
Definition: system.cpp:3016
int str_utf8_comp_nocase_num(const char *a, const char *b, int num)
Definition: system.cpp:3727
const char * str_endswith_nocase(const char *str, const char *suffix)
Definition: system.cpp:3042
unsigned bytes_be_to_uint(const unsigned char *bytes)
Definition: system.cpp:4126
int str_utf8_rewind(const char *str, int cursor)
Definition: system.cpp:3841
int str_utf8_fix_truncation(char *str)
Definition: system.cpp:3852
const char * str_endswith(const char *str, const char *suffix)
Definition: system.cpp:3062
const char * str_find(const char *haystack, const char *needle)
Definition: system.cpp:3187
char str_uppercase(char c)
Definition: system.cpp:3628
int net_udp_recv(NETSOCKET sock, NETADDR *addr, unsigned char **data)
Definition: system.cpp:1800
int64_t str_toint64_base(const char *str, int base=10)
Definition: system.cpp:3689
int str_utf8_tolower(int code)
Definition: tolower.cpp:12
int str_utf8_to_skeleton(const char *str, int *buf, int buf_len)
Definition: confusables.cpp:66
int(* FS_LISTDIR_CALLBACK_FILEINFO)(const CFsFileInfo *info, int is_dir, int dir_type, void *user)
Definition: types.h:29
int(* FS_LISTDIR_CALLBACK)(const char *name, int is_dir, int dir_type, void *user)
Definition: types.h:20
float length(const vector2_base< float > &a)
Definition: vmath.h:104