diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-14 14:34:15 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-14 14:34:15 +0000 |
commit | 65798fc55f1477913f38d8b6c8c153ba54e1f835 (patch) | |
tree | bf186bfdd5fb9b0b1ec97c177c9700a17666f6a4 | |
parent | 7c5a774b0d743940326528bc1d6b3102e5ae8210 (diff) | |
download | alpine_aports-65798fc55f1477913f38d8b6c8c153ba54e1f835.tar.bz2 alpine_aports-65798fc55f1477913f38d8b6c8c153ba54e1f835.tar.xz alpine_aports-65798fc55f1477913f38d8b6c8c153ba54e1f835.zip |
core/apk-tools: remove unused patches
-rw-r--r-- | core/apk-tools/fd-leak.patch | 24 | ||||
-rw-r--r-- | core/apk-tools/fd-leak2.patch | 30 |
2 files changed, 0 insertions, 54 deletions
diff --git a/core/apk-tools/fd-leak.patch b/core/apk-tools/fd-leak.patch deleted file mode 100644 index 5f6a55ff80..0000000000 --- a/core/apk-tools/fd-leak.patch +++ /dev/null | |||
@@ -1,24 +0,0 @@ | |||
1 | commit bd6278fb28d1d87a58a591244fe1069aa4216a6f | ||
2 | Author: Natanael Copa <ncopa@alpinelinux.org> | ||
3 | Date: Tue May 26 14:12:02 2009 +0000 | ||
4 | |||
5 | fetch: fix fd leak | ||
6 | |||
7 | we should always close the in-stream, not only on failure. | ||
8 | |||
9 | diff --git a/src/fetch.c b/src/fetch.c | ||
10 | index 9e0d930..f3c651b 100644 | ||
11 | --- a/src/fetch.c | ||
12 | +++ b/src/fetch.c | ||
13 | @@ -95,10 +95,10 @@ static int fetch_package(struct fetch_ctx *fctx, | ||
14 | } | ||
15 | |||
16 | r = apk_istream_splice(is, fd, pkg->size, NULL, NULL); | ||
17 | + is->close(is); | ||
18 | if (fd != STDOUT_FILENO) | ||
19 | close(fd); | ||
20 | if (r != pkg->size) { | ||
21 | - is->close(is); | ||
22 | apk_error("Unable to download '%s'", file); | ||
23 | unlink(file); | ||
24 | return -1; | ||
diff --git a/core/apk-tools/fd-leak2.patch b/core/apk-tools/fd-leak2.patch deleted file mode 100644 index 033bc0dc19..0000000000 --- a/core/apk-tools/fd-leak2.patch +++ /dev/null | |||
@@ -1,30 +0,0 @@ | |||
1 | commit 49c904c993d39cfac7d3373c66f5b910e755f203 | ||
2 | Author: Timo Teras <timo.teras@iki.fi> | ||
3 | Date: Thu Jun 11 13:03:10 2009 +0300 | ||
4 | |||
5 | io: fix mmap bstream fd leak | ||
6 | |||
7 | We need to close the fd on destruction. This is what the corresponding | ||
8 | istream variant does too. | ||
9 | |||
10 | diff --git a/src/io.c b/src/io.c | ||
11 | index e0a9c9b..defbe46 100644 | ||
12 | --- a/src/io.c | ||
13 | +++ b/src/io.c | ||
14 | @@ -4,7 +4,7 @@ | ||
15 | * Copyright (C) 2008 Timo Teräs <timo.teras@iki.fi> | ||
16 | * All rights reserved. | ||
17 | * | ||
18 | - * This program is free software; you can redistribute it and/or modify it | ||
19 | + * This program is free software; you can redistribute it and/or modify it | ||
20 | * under the terms of the GNU General Public License version 2 as published | ||
21 | * by the Free Software Foundation. See http://www.gnu.org/ for details. | ||
22 | */ | ||
23 | @@ -257,6 +257,7 @@ static void mmap_close(void *stream, csum_t csum, size_t *size) | ||
24 | *size = mbs->size; | ||
25 | |||
26 | munmap(mbs->ptr, mbs->size); | ||
27 | + close(mbs->fd); | ||
28 | free(mbs); | ||
29 | } | ||
30 | |||