Merge remote-tracking branch 'zyx-i/fix-567' into develop
This commit is contained in:
commit
fc6d85219f
|
@ -177,6 +177,8 @@ def file_size(pl, suffix='B', si_prefix=False):
|
|||
# Note: returns file size in &encoding, not in &fileencoding. But returned
|
||||
# size is updated immediately; and it is valid for any buffer
|
||||
file_size = vim_funcs['line2byte'](len(vim.current.buffer) + 1) - 1
|
||||
if file_size < 0:
|
||||
file_size = 0
|
||||
return humanize_bytes(file_size, suffix, si_prefix)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue