summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2009-09-08 14:10:34 +0300
committerPanu Matilainen <pmatilai@redhat.com>2009-09-09 10:57:30 +0300
commit5a13d2ed21da68b4d9f16c1266ab1250f646c9e0 (patch)
tree4ecd93b75be7318d070074086266059c30f788d8
parentf3389c8794f99685eb9bd113b48dd844a93c57cc (diff)
downloadrpm-5a13d2ed21da68b4d9f16c1266ab1250f646c9e0.tar.gz
rpm-5a13d2ed21da68b4d9f16c1266ab1250f646c9e0.tar.bz2
rpm-5a13d2ed21da68b4d9f16c1266ab1250f646c9e0.zip
Move variable to block local scope, not needed elsewhere
-rw-r--r--lib/header.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/header.c b/lib/header.c
index 1fdff9be5..74cee5053 100644
--- a/lib/header.c
+++ b/lib/header.c
@@ -245,7 +245,6 @@ unsigned headerSizeof(Header h, enum hMagic magicp)
size += 2 * sizeof(int32_t); /* count of index entries */
for (i = 0, entry = h->index; i < h->indexUsed; i++, entry++) {
- unsigned diff;
rpmTagType type;
/* Regions go in as is ... */
@@ -264,7 +263,7 @@ unsigned headerSizeof(Header h, enum hMagic magicp)
/* Alignment */
type = entry->info.type;
if (typeSizes[type] > 1) {
- diff = typeSizes[type] - (size % typeSizes[type]);
+ unsigned diff = typeSizes[type] - (size % typeSizes[type]);
if (diff != typeSizes[type]) {
size += diff;
pad += diff;