diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2008-04-24 17:46:28 -0300 |
---|---|---|
committer | Otavio Salvador <otavio@ossystems.com.br> | 2008-04-26 20:44:57 -0300 |
commit | c092d19ecdd04f0805e52b7671b91678a2bb74e2 (patch) | |
tree | 2660f63feab63c14c1c705740711caa42a132bdd /libparted/exception.c | |
parent | abc24c32fc7bca23d9cd2b82b1bcafec6c4b5f21 (diff) | |
download | parted-c092d19ecdd04f0805e52b7671b91678a2bb74e2.tar.gz |
do not loop in case message exception has no message
The exception handler was looping when the exception had no message.
Diffstat (limited to 'libparted/exception.c')
-rw-r--r-- | libparted/exception.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libparted/exception.c b/libparted/exception.c index c9a50bb..5fb3c79 100644 --- a/libparted/exception.c +++ b/libparted/exception.c @@ -242,7 +242,7 @@ ped_exception_throw (PedExceptionType ex_type, ex->type = ex_type; ex->options = ex_opts; - while (1) { + while (message) { ex->message = (char*) malloc (size * sizeof (char)); if (!ex->message) goto no_memory; |