]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Use talloc for handles
authorAlan T. DeKok <aland@freeradius.org>
Sat, 16 Mar 2013 18:03:25 +0000 (14:03 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Sat, 16 Mar 2013 18:03:25 +0000 (14:03 -0400)
src/modules/rlm_smsotp/rlm_smsotp.c

index 693426c04d5dada6d2cf27855f74edb8e38fdecf..e561da8756b687d0e1eacc53a2a04328ae6f1178 100644 (file)
@@ -73,7 +73,7 @@ static void *conn_create(void *ctx)
                return NULL;
        }
 
-       fdp = rad_malloc(sizeof(*fdp));
+       fdp = talloc_zero(ctx, int);
        *fdp = fd;
 
        return fdp;
@@ -84,7 +84,7 @@ static int conn_delete(UNUSED void *ctx, void *connection)
        int *fdp = connection;
 
        close(*fdp);
-       free(fdp);
+       talloc_free(fdp);
        return 0;
 }