|
From: | shishi-commit |
Subject: | Fix reading keys. |
Date: | Wed, 10 Dec 2003 07:00:45 +0100 |
Commit from jas | 2003-12-10 07:00 CET |
Fix reading keys.
Module | File name | Revision | |||
---|---|---|---|---|---|
shishi | db/file.c | 1.16 | >>> | 1.17 |
shishi/db/file.c 1.16 >>> 1.17 |
---|
Line 413 |
ssize_t len; int rc; |
- asprintf (&file, "%s/%s/%s/keys/%s", info->path, realm, principal, keyfile); - fh = fopen (file, "r"); |
+ asprintf (&file, "keys/%s", keyfile); + fh = _shisa_fopen4 (info->path, realm, principal, file, "r"); + free (file); |
if (!fh) return SHISA_NO_KEY; |
Line 460 |
rc = fclose (fh); if (rc != 0) { |
- perror(file); |
+ perror(keyfile); |
return SHISA_NO_KEY; } |
- free (file); - |
*key = xmalloc (sizeof (**key)); memcpy (*key, &tmpkey, sizeof (tmpkey)); |
[Prev in Thread] | Current Thread | [Next in Thread] |