aboutsummaryrefslogtreecommitdiffstats
path: root/agent/trustlist.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2009-12-02 19:00:10 +0000
committerWerner Koch <[email protected]>2009-12-02 19:00:10 +0000
commitedd95da365b92832692c646fe815fcca50aadba3 (patch)
treed8d61754edd658367c082221d87af3f068e4b8b8 /agent/trustlist.c
parentMore stuff for the audit-log. (diff)
downloadgnupg-edd95da365b92832692c646fe815fcca50aadba3.tar.gz
gnupg-edd95da365b92832692c646fe815fcca50aadba3.zip
Fix usage of realloc.
Diffstat (limited to 'agent/trustlist.c')
-rw-r--r--agent/trustlist.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/agent/trustlist.c b/agent/trustlist.c
index a0b23b51f..be5406b05 100644
--- a/agent/trustlist.c
+++ b/agent/trustlist.c
@@ -361,13 +361,14 @@ read_trustfiles (void)
ti = xtryrealloc (table, (tableidx?tableidx:1) * sizeof *table);
if (!ti)
{
+ err = gpg_error_from_syserror ();
xfree (table);
return err;
}
lock_trusttable ();
xfree (trusttable);
- trusttable = table;
+ trusttable = ti;
trusttablesize = tableidx;
unlock_trusttable ();
return 0;