cleanup, docs
This commit is contained in:
+7
-7
@@ -16,7 +16,7 @@ typedef int pid_t;
|
||||
extern "C" {
|
||||
int raise(int);
|
||||
unsigned int sleep(unsigned int seconds);
|
||||
int usleep(unsigned int usec);
|
||||
s32 usleep(u32 usec);
|
||||
}
|
||||
#else
|
||||
#include <sys/file.h>
|
||||
@@ -59,7 +59,7 @@ String file_read(u64 h, u64 len);
|
||||
String file_pread(u64 h, u64 offset, u64 len);
|
||||
u64 file_write(u64 h, String data);
|
||||
u64 file_pwrite(u64 h, u64 offset, String data);
|
||||
s64 file_seek(u64 h, s64 offset, int whence);
|
||||
s64 file_seek(u64 h, s64 offset, s64 whence);
|
||||
s64 file_tell(u64 h);
|
||||
void file_close(u64 h);
|
||||
DValue file_stat(String path);
|
||||
@@ -82,7 +82,7 @@ inline bool file_append(String file_name, Ts... args)
|
||||
String cwd_get();
|
||||
void cwd_set(String path);
|
||||
String process_start_directory();
|
||||
time_t file_mtime(String file_name);
|
||||
u64 file_mtime(String file_name);
|
||||
void file_unlink(String file_name);
|
||||
String expand_path(String path, String relative_to_path = "");
|
||||
StringList ls(String dir);
|
||||
@@ -97,7 +97,7 @@ String time_format_utc(String format = "", u64 timestamp = 0);
|
||||
String time_format_relative(u64 timestamp, String format_very_recent = "", u64 medium_recency_seconds = 0, String format_medium_recent = "", u64 not_recent_seconds = 0, String format_not_recent = "");
|
||||
u64 time_parse(String time_String);
|
||||
|
||||
u64 socket_connect(String host, short port);
|
||||
u64 socket_connect(String host, u16 port);
|
||||
void socket_close(u64 sockfd);
|
||||
bool socket_write(u64 sockfd, String data);
|
||||
String socket_read(u64 sockfd, u32 max_length = 1024*128, u32 timeout = 1);
|
||||
@@ -115,11 +115,11 @@ bool ws_close(String connection_id = "");
|
||||
|
||||
String backtrace_get_frames(void* const* frames, size_t size, u32 skip_frames = 0);
|
||||
String backtrace_capture(u32 max_frames = 32, u32 skip_frames = 0);
|
||||
String signal_name(int sig);
|
||||
String signal_name(s32 sig);
|
||||
|
||||
String memcache_escape_key(String key);
|
||||
StringList memcache_escape_keys(StringList keys);
|
||||
u64 memcache_connect(String host = "127.0.0.1", short port = 11211);
|
||||
u64 memcache_connect(String host = "127.0.0.1", u16 port = 11211);
|
||||
String memcache_command(u64 connection, String command);
|
||||
bool memcache_set(u64 connection, String key, String value, u64 expires_in = 60*60);
|
||||
bool memcache_delete(u64 connection, String key);
|
||||
@@ -137,7 +137,7 @@ extern pid_t my_pid;
|
||||
#endif
|
||||
|
||||
void on_segfault(int sig);
|
||||
int task_kill(pid_t pid, int sig = 0);
|
||||
int task_kill(pid_t pid, s32 sig = 0);
|
||||
|
||||
String runtime_safe_key(String key, String label = "runtime key");
|
||||
pid_t task(String key, std::function<void()> exec_after_spawn, u64 timeout = 60*10);
|
||||
|
||||
Reference in New Issue
Block a user