mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-05-31 06:13:55 +00:00
update hint and code style
This commit is contained in:
parent
7d4573cdd4
commit
f8efcea0b0
@ -29,8 +29,7 @@ const static int8_t b64_decode_table[256] = {
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1 /* F0-FF */
|
||||
};
|
||||
|
||||
uint8_t *base64decode(const uint8_t *src, const size_t buflen, size_t *retlen)
|
||||
{
|
||||
uint8_t *base64decode(const uint8_t *src, const size_t buflen, size_t *retlen){
|
||||
int8_t digit, lastdigit;
|
||||
size_t i, j;
|
||||
uint8_t *decoded;
|
||||
@ -65,8 +64,7 @@ uint8_t *base64decode(const uint8_t *src, const size_t buflen, size_t *retlen)
|
||||
return decoded; /* Must be free()'d by caller */
|
||||
}
|
||||
|
||||
uint8_t *base64encode(const uint8_t *src, const size_t buflen, size_t *retlen)
|
||||
{
|
||||
uint8_t *base64encode(const uint8_t *src, const size_t buflen, size_t *retlen){
|
||||
size_t i, j;
|
||||
const size_t maxlen = (((buflen + 3) & ~3)) * 4;
|
||||
uint8_t *encoded = malloc(maxlen + 1);
|
||||
|
@ -6,8 +6,7 @@
|
||||
|
||||
#define ZLIB_CHUNK (16 * 1024)
|
||||
|
||||
uint8_t *zlib_decompress(const uint8_t *buf, size_t *len)
|
||||
{
|
||||
uint8_t *zlib_decompress(const uint8_t *buf, size_t *len){
|
||||
size_t output_size = ZLIB_CHUNK;
|
||||
uint8_t *output = malloc(output_size);
|
||||
int err;
|
||||
|
@ -79,7 +79,7 @@ char* set_XDisplay_name(char* name){
|
||||
setXDisplay(name);
|
||||
return "success";
|
||||
#else
|
||||
return "setXDisplayName is only supported on Linux";
|
||||
return "SetXDisplayName is only supported on Linux";
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -91,7 +91,7 @@ char* get_XDisplay_name(){
|
||||
|
||||
return sd;
|
||||
#else
|
||||
return "getXDisplayName is only supported on Linux";
|
||||
return "GetXDisplayName is only supported on Linux";
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user