OSDN Git Service

rng-egd: remove redundant free
authorAmos Kong <akong@redhat.com>
Thu, 21 Nov 2013 08:42:50 +0000 (16:42 +0800)
committerAnthony Liguori <aliguori@amazon.com>
Thu, 21 Nov 2013 15:55:37 +0000 (07:55 -0800)
We didn't set default chr_name, the free is redundant.

Signed-off-by: Amos Kong <akong@redhat.com>
Message-id: 1385023371-8198-2-git-send-email-akong@redhat.com
Signed-off-by: Anthony Liguori <aliguori@amazon.com>
backends/rng-egd.c

index 9e5a536..6f56f9e 100644 (file)
@@ -167,7 +167,6 @@ static void rng_egd_set_chardev(Object *obj, const char *value, Error **errp)
     if (b->opened) {
         error_set(errp, QERR_PERMISSION_DENIED);
     } else {
-        g_free(s->chr_name);
         s->chr_name = g_strdup(value);
     }
 }