OSDN Git Service

bsd: avoid NULL-deref-on-OOM and an error-path leak
authorJim Meyering <meyering@redhat.com>
Fri, 27 May 2011 12:24:33 +0000 (14:24 +0200)
committerJim Meyering <meyering@redhat.com>
Fri, 27 May 2011 12:24:33 +0000 (14:24 +0200)
commit3259d570c7e58d317a823994200183501eff7092
treebbc867df264fe8d68fbb7b3be6fafbc9563289a2
parentaff3ed70d47ae8e2da057d00dd3d4ab08b0cf574
bsd: avoid NULL-deref-on-OOM and an error-path leak

* libparted/labels/bsd.c (bsd_read): Don't dereference NULL on OOM.
Don't leak a constraint when failing to add a partition.
libparted/labels/bsd.c