mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-25 09:48:09 +02:00
Basic rsync transmission works
This commit is contained in:
@@ -260,7 +260,7 @@ sign_block(Patcher *self, PyObject *args) {
|
||||
return PyLong_FromSize_t(signature_block_size);
|
||||
}
|
||||
|
||||
typedef enum { OpBlock, OpBlockRange, OpHash, OpData } OpType;
|
||||
typedef enum { OpBlock, OpData, OpHash, OpBlockRange } OpType;
|
||||
|
||||
typedef struct Operation {
|
||||
OpType type;
|
||||
@@ -268,6 +268,8 @@ typedef struct Operation {
|
||||
struct { uint8_t *buf; size_t len; } data;
|
||||
} Operation;
|
||||
|
||||
#define bytes_as_hex_for_debug(data, len) PyUnicode_AsUTF8(PyObject_CallMethod(PyBytes_FromStringAndSize((char*)data, len), "hex", NULL))
|
||||
|
||||
static size_t
|
||||
unserialize_op(uint8_t *data, size_t len, Operation *op) {
|
||||
size_t consumed = 0;
|
||||
|
||||
Reference in New Issue
Block a user