[svn:parrot] r44028 - branches/tt_1449/src/pmc
whiteknight at svn.parrot.org
whiteknight at svn.parrot.org
Tue Feb 16 16:40:26 UTC 2010
Author: whiteknight
Date: Tue Feb 16 16:40:26 2010
New Revision: 44028
URL: https://trac.parrot.org/parrot/changeset/44028
Log:
[tt_1449] some error handling, need to check what Parrot_get_namespace_keyed_str returns in these situations
Modified:
branches/tt_1449/src/pmc/namespace.pmc
Modified: branches/tt_1449/src/pmc/namespace.pmc
==============================================================================
--- branches/tt_1449/src/pmc/namespace.pmc Tue Feb 16 16:37:25 2010 (r44027)
+++ branches/tt_1449/src/pmc/namespace.pmc Tue Feb 16 16:40:26 2010 (r44028)
@@ -427,6 +427,11 @@
INTVAL i = 0;
while (!PMC_IS_NULL(ns) && VTABLE_elements(INTERP, key)) {
STRING * const name = VTABLE_get_string_keyed_int(INTERP, key, i);
+ if (name == NULL || name == STRINGNULL) {
+ ns = PMCNULL;
+ // TODO: Throw an exception or something?
+ break;
+ }
ns = Parrot_get_namespace_keyed_str(INTERP, ns, name);
i++;
}
More information about the parrot-commits
mailing list