mirror of
https://github.com/Ascyii/vim-gnupg.git
synced 2026-01-01 14:24:25 -05:00
Convert the output of gpg to the correct encoding.
This commit is contained in:
@@ -839,6 +839,12 @@ fun s:GPGNameToID(name)
|
||||
let &shellredir=s:shellredirsave
|
||||
let &shell=s:shellsave
|
||||
|
||||
" when called with "--with-colons" gpg encodes its output _ALWAYS_ as UTF-8,
|
||||
" so convert it, if necessary
|
||||
if &encoding != "utf-8"
|
||||
let output=iconv(output, "utf-8", &encoding)
|
||||
endi
|
||||
|
||||
" parse the output of gpg
|
||||
let pub_seen=0
|
||||
let uid_seen=0
|
||||
@@ -903,6 +909,12 @@ fun s:GPGIDToName(identity)
|
||||
let &shellredir=s:shellredirsave
|
||||
let &shell=s:shellsave
|
||||
|
||||
" when called with "--with-colons" gpg encodes its output _ALWAYS_ as UTF-8,
|
||||
" so convert it, if necessary
|
||||
if &encoding != "utf-8"
|
||||
let output=iconv(output, "utf-8", &encoding)
|
||||
endi
|
||||
|
||||
" parse the output of gpg
|
||||
let pub_seen=0
|
||||
let finish=0
|
||||
|
||||
Reference in New Issue
Block a user