X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=client-src%2Fselfcheck.c;fp=client-src%2Fselfcheck.c;h=7716c89468e8ed656563d49708213ec9a6c2e442;hb=d28952249e392eb31bc8eecc53f6c477f30c617b;hp=8cd7b539361b8f7d7fe9c004e0694950e8c75133;hpb=949b8910a5e23c4285d0b1aedacfc82a14dc97a5;p=debian%2Famanda diff --git a/client-src/selfcheck.c b/client-src/selfcheck.c index 8cd7b53..7716c89 100644 --- a/client-src/selfcheck.c +++ b/client-src/selfcheck.c @@ -1,6 +1,7 @@ /* * Amanda, The Advanced Maryland Automatic Network Disk Archiver * Copyright (c) 1991-1998 University of Maryland at College Park + * Copyright (c) 2007-2012 Zmanda, Inc. All Rights Reserved. * All Rights Reserved. * * Permission to use, copy, modify, distribute, and sell this software and its @@ -1232,8 +1233,7 @@ print_platform(void) FILE *release = fopen("/etc/lsb-release", "r"); distro = "Ubuntu"; if (release) { - char *result; - while ((result = fgets(line, 1024, release))) { + while (fgets(line, 1024, release)) { if (strstr(line, "DESCRIPTION")) { platform = strchr(line, '='); if (platform) platform++; @@ -1280,8 +1280,8 @@ print_platform(void) if (result) { platform = line; } + fclose(release); } - fclose(release); } amfree(uname); }