mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-27 18:51:41 +02:00
Fix usage of chunk_num
This commit is contained in:
@@ -1022,7 +1022,7 @@ class Window:
|
|||||||
num, rest = msg.split(':', 1)
|
num, rest = msg.split(':', 1)
|
||||||
if num == '0' or len(self.current_clone_data) > 1024 * 1024:
|
if num == '0' or len(self.current_clone_data) > 1024 * 1024:
|
||||||
self.current_clone_data = ''
|
self.current_clone_data = ''
|
||||||
self.current_clone_data += msg
|
self.current_clone_data += rest
|
||||||
|
|
||||||
def handle_remote_askpass(self, msg: str) -> None:
|
def handle_remote_askpass(self, msg: str) -> None:
|
||||||
from .shm import SharedMemory
|
from .shm import SharedMemory
|
||||||
|
|||||||
@@ -370,7 +370,7 @@ clone-in-kitty() {
|
|||||||
while [ $pos -lt ${#data} ]; do
|
while [ $pos -lt ${#data} ]; do
|
||||||
builtin local chunk="${data:$pos:2048}"
|
builtin local chunk="${data:$pos:2048}"
|
||||||
pos=$(($pos+2048))
|
pos=$(($pos+2048))
|
||||||
builtin print -nu "$_ksi_fd" '\eP@kitty-clone|'"${chunk}:"'\e\\'
|
builtin print -nu "$_ksi_fd" -f '\eP@kitty-clone|%s:%s\e\\' "${chunk_num}" "${chunk}"
|
||||||
chunk_num=$(($chunk_num+1))
|
chunk_num=$(($chunk_num+1))
|
||||||
done
|
done
|
||||||
builtin print -nu "$_ksi_fd" '\eP@kitty-clone|\e\\'
|
builtin print -nu "$_ksi_fd" '\eP@kitty-clone|\e\\'
|
||||||
|
|||||||
Reference in New Issue
Block a user