diff options
author | mlaurent <mlaurent@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-07 12:33:37 +0000 |
---|---|---|
committer | mlaurent <mlaurent@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-07 12:33:37 +0000 |
commit | ea4554905e6d763bcde9b555e0c9544b4037e5de (patch) | |
tree | 6a9c4ab79ca2a139d3563b5c8cb882b824d0e223 | |
parent | 9d0ad6fd0a3e2ba748b7b81f5031d6170c8bc026 (diff) | |
download | libvncserver-krfb.zip libvncserver-krfb.tar.gz |
Fix mem leakkrfb
git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/KDE/kdenetwork/krfb/libvncserver@1212554 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
-rw-r--r-- | vncauth.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -118,10 +118,10 @@ rfbDecryptPasswdFromFile(char *fname) { FILE *fp; int i, ch; - unsigned char *passwd = (unsigned char *)malloc(9); - if ((fp = fopen(fname,"r")) == NULL) return NULL; + unsigned char *passwd = (unsigned char *)malloc(9); + for (i = 0; i < 8; i++) { ch = getc(fp); if (ch == EOF) { |