From 8901e010fa24ba375d53e3e37fc7819621adcf19 Mon Sep 17 00:00:00 2001 From: Ondrej Oprala Date: Tue, 22 Jan 2013 14:21:23 +0100 Subject: dd: avoid buffer allocations unless needed * src/dd.c: Add new static global variable ibuf. (alloc_ibuf, alloc_obuf): New functions factored from dd_copy(). (dd_copy): Call the new functions to allocate memory for ibuf and obuf when necessary. (skip): Likewise. * tests/dd/no-allocate.sh: New test. * tests/local.mk: Reference the test. --- tests/local.mk | 1 + 1 file changed, 1 insertion(+) (limited to 'tests/local.mk') diff --git a/tests/local.mk b/tests/local.mk index e3a72ab3a..0b019d951 100644 --- a/tests/local.mk +++ b/tests/local.mk @@ -465,6 +465,7 @@ all_tests = \ tests/df/skip-rootfs.sh \ tests/dd/direct.sh \ tests/dd/misc.sh \ + tests/dd/no-allocate.sh \ tests/dd/nocache.sh \ tests/dd/not-rewound.sh \ tests/dd/reblock.sh \ -- cgit v1.2.3-54-g00ecf