1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-26 03:22:12 +03:00
lvm2/test
mpatocka 31b3571d31 Change exit() to _exit() in the child process. exit flushes stdio file buffers,
_exit doesn't. If there were some open files, an error in exec and subsequent
exit() would cause the buffers to be flushed twice.

Example:

#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/wait.h>

int main()
{
	printf("buu");
	if (!fork()) {
		execl("/bin/true-not-exists", "/bin/true", NULL);
		exit(1);
	}
	wait(NULL);
	return 0;
}

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com

---
 daemons/dmeventd/libdevmapper-event.c |    2 +-
 lib/misc/lvm-exec.c                   |    2 +-
 test/harness.c                        |    3 ++-
 tools/dmsetup.c                       |    2 +-
 4 files changed, 5 insertions(+), 4 deletions(-)
2009-07-13 21:26:41 +00:00
..
api Rename liblvm.so to liblvm2app.so and use configure --enable-applib. 2009-05-22 14:44:59 +00:00
.gitignore Add testing framework, along with first few tests. 2007-09-18 14:00:42 +00:00
harness.c Change exit() to _exit() in the child process. exit flushes stdio file buffers, 2009-07-13 21:26:41 +00:00
harness.sh Also report the tests that have been skipped, at the end of harness.sh. 2008-11-04 14:37:51 +00:00
lvm-utils.sh Add tests to check pv_mda_size and vg_mda_size. 2009-05-08 06:10:45 +00:00
Makefile.in Fix some distclean rules. 2009-03-16 18:28:04 +00:00
mkdtemp Clean-up and wording changes; add copyright notices. 2007-09-18 14:02:22 +00:00
not.c In testsuite's not.c, print a notice when program dies of a fatal signal. 2009-02-17 19:37:28 +00:00
t-000-basic.sh Get rid of the mdadm presence check in t-000-basic: no actual test uses 2009-07-13 12:42:26 +00:00
t-covercmd.sh Continue to make --units and --size consistent (in code and man pages): 2009-07-07 19:28:57 +00:00
t-fsadm.sh Add skeleton of fsadm nightly test but skip (doesn't work yet). 2009-01-15 17:14:38 +00:00
t-inconsistent-metadata.sh Fix t-inconsistent-metadata.sh. 2009-07-01 17:06:04 +00:00
t-listings.sh Fix pvseg report for orphan PVs and other devices. 2009-04-21 12:59:18 +00:00
t-lvconvert-repair.sh Use lvconvert --repair instead of vgreduce in mirror dmeventd DSO (mornfall) 2009-06-04 12:01:15 +00:00
t-lvcreate-operation.sh Import a bunch of new tests by jstava. Mostly everything pass, they however 2008-11-11 15:29:24 +00:00
t-lvcreate-pvtags.sh Minor code and documentation cleanups and changes by jstava. 2008-11-10 12:43:35 +00:00
t-lvcreate-usage.sh Fix rename of active snapshot with virtual origin. 2009-06-01 15:55:06 +00:00
t-lvextend-percent-extents.sh Add test for seg_start, seg_count, seg_start_pe 2009-05-11 03:37:34 +00:00
t-lvm-init.sh Add t-lvm-init.sh - test lvm init routines and error paths. 2009-07-08 18:14:47 +00:00
t-lvmcache-exercise.sh Update a bunch of tests to use functionality from test-utils.sh. 2008-09-29 16:02:50 +00:00
t-lvresize-usage.sh Update a bunch of tests to use functionality from test-utils.sh. 2008-09-29 16:02:50 +00:00
t-mdata-strings.sh Fix whitespace in t-mdata-strings.sh 2009-04-03 14:23:17 +00:00
t-metadata.sh Add a bunch of sub-tests aimed at testing various bugzillas, by jstava. 2008-11-11 15:46:15 +00:00
t-mirror-basic.sh bz429342 lvcreate --nosync 2008-11-10 12:37:53 +00:00
t-mirror-lvconvert-usage.sh Import a bunch of new tests by jstava. Mostly everything pass, they however 2008-11-11 15:29:24 +00:00
t-mirror-lvconvert.sh Fix convert polling to ignore LV with different UUID. 2009-06-01 14:43:27 +00:00
t-mirror-names.sh add bz264241 check 2008-11-10 12:41:52 +00:00
t-mirror-vgreduce-removemissing.sh Explicitly check after lvremove -ff vg that it did its job. By jstava. 2008-11-10 12:32:00 +00:00
t-partial-activate.sh Fix vgreduce --removemissing failure exit code. 2009-04-22 17:00:28 +00:00
t-pool-labels.sh Fix t-pool-labels to pass again after the vgdisplay error return fix from 2008-11-10 13:44:01 +00:00
t-pv-range-overflow.sh More test conversions by jstava. Make check still passes. 2008-10-06 16:47:07 +00:00
t-pvchange-usage.sh More test conversions by jstava. Make check still passes. 2008-10-06 16:47:07 +00:00
t-pvcreate-metadata0.sh More test conversions by jstava. Make check still passes. 2008-10-06 16:47:07 +00:00
t-pvcreate-operation.sh Fix various problems in tests 2009-06-06 16:40:39 +00:00
t-pvcreate-usage.sh Fix various problems in tests 2009-06-06 16:40:39 +00:00
t-pvmove-basic.sh If pvmove fails activating mirror volume, try restore to previous state. 2009-05-19 09:51:02 +00:00
t-pvremove-usage.sh add bz264241 check 2008-11-10 12:41:52 +00:00
t-read-ahead.sh Fix various problems in tests 2009-06-06 16:40:39 +00:00
t-unlost-pv.sh Allow metadata correction even when PVs are missing. 2009-06-10 20:17:32 +00:00
t-vgcfgbackup-usage.sh Use PV UUID in hash for device name when exporting metadata. 2009-05-19 09:48:32 +00:00
t-vgchange-usage.sh Import a bunch of new tests by jstava. Mostly everything pass, they however 2008-11-11 15:29:24 +00:00
t-vgcreate-usage.sh Update t-vgcreate-usage.sh to check for default vg properties. 2009-07-09 08:50:55 +00:00
t-vgmerge-operation.sh add bz264241 check 2008-11-10 12:41:52 +00:00
t-vgmerge-usage.sh More test conversions by jstava. Make check still passes. 2008-10-06 16:47:07 +00:00
t-vgreduce-usage.sh Minor code and documentation cleanups and changes by jstava. 2008-11-10 12:43:35 +00:00
t-vgrename-usage.sh Add vgrename test to check for existence of new vg. 2009-06-05 10:42:22 +00:00
t-vgsplit-operation.sh Fix [ a = b ] usage in t-vgsplit-operation: string comparison is '=', not '=='. 2008-09-30 18:29:10 +00:00
t-vgsplit-usage.sh Minor code and documentation cleanups and changes by jstava. 2008-11-10 12:43:35 +00:00
test-lib.sh Export testlib_cleanup_ from test-lib.sh, which is needed for test-utils.sh to 2008-09-29 16:00:53 +00:00
test-utils.sh Check max_lv on only place and force the check only for new volume. 2009-05-13 21:29:10 +00:00