uxpgnt --askpass: explicitly fflush(stdout) on exit.

I'm not really sure why that's necessary: by my understanding of the C
standard, it shouldn't be. But my observation is that when compiling
with {Address,Leak} Sanitiser enabled, pageant --askpass can somehow
manage to exit without having actually written the passphrase to its
standard output.

(cherry picked from commit c618d6baac)
This commit is contained in:
Simon Tatham 2020-02-08 18:57:57 +00:00
Родитель 706eb63c31
Коммит 11d67b5a91
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -1093,6 +1093,8 @@ int main(int argc, char **argv)
return 1;
puts(passphrase);
fflush(stdout);
smemclr(passphrase, strlen(passphrase));
sfree(passphrase);
return 0;