ios: update chat_read_file (#3037)
This commit is contained in:
committed by
GitHub
parent
e76440ee66
commit
113a57c7c7
@@ -26,16 +26,17 @@ extern char *chat_password_hash(char *pwd, char *salt);
|
||||
extern char *chat_encrypt_media(char *key, char *frame, int len);
|
||||
extern char *chat_decrypt_media(char *key, char *frame, int len);
|
||||
|
||||
// chat_write_file returns NUL-terminated string with JSON of WriteFileResult
|
||||
// chat_write_file returns null-terminated string with JSON of WriteFileResult
|
||||
extern char *chat_write_file(char *path, char *data, int len);
|
||||
|
||||
// chat_read_file returns a buffer with:
|
||||
// 1. NUL-terminated C string with JSON of ReadFileResult, followed by
|
||||
// 2. file data, the length is defined in ReadFileResult
|
||||
// result status (1 byte), then if
|
||||
// status == 0 (success): buffer length (uint32, 4 bytes), buffer of specified length.
|
||||
// status == 1 (error): null-terminated error message string.
|
||||
extern char *chat_read_file(char *path, char *key, char *nonce);
|
||||
|
||||
// chat_encrypt_file returns NUL-terminated string with JSON of WriteFileResult
|
||||
// chat_encrypt_file returns null-terminated string with JSON of WriteFileResult
|
||||
extern char *chat_encrypt_file(char *fromPath, char *toPath);
|
||||
|
||||
// chat_decrypt_file returns NUL-terminated string with the error message
|
||||
// chat_decrypt_file returns null-terminated string with the error message
|
||||
extern char *chat_decrypt_file(char *fromPath, char *key, char *nonce, char *toPath);
|
||||
|
||||
Reference in New Issue
Block a user