add: dump("Exception caught in 'saveCategory': " + ex + "\n"); 
context:     saveCategory: function (categoryName, categoryColor) {        var list = document.getElementById("categorieslist");        // Check to make sure another category doesn't have the same name        var toBeDeleted = -1;        var promptService =              Components.classes["@mozilla.org/embedcomp/prompt-service;1"]                       .getService(Components.interfaces.nsIPromptService);        for (var i=0; i < gCategoryList.length; i++) {            if (i == list.selectedIndex)                continue;            if (categoryName.toLowerCase() == gCategoryList[i].toLowerCase()) {                if (promptService.confirm(null, overwriteTitle, overwrite)) {                    if (list.selectedIndex != -1)                        // Don't delete the old category yet. It will mess up indices.                        toBeDeleted = list.selectedIndex;                    list.selectedIndex = i;                } else {                    return;                }            }        }        if (categoryName.length == 0) {            promptService.alert(null, null, noBlankCategories);            return;        }        var categoryNameFix = this.fixName(categoryName);        if (list.selectedIndex == -1) {            this.backupData(categoryNameFix);            gCategoryList.push(categoryName);            if (categoryColor)                categoryPrefBranch.setCharPref(categoryNameFix, categoryColor);        } else {            this.backupData(categoryNameFix);            gCategoryList.splice(list.selectedIndex, 1, categoryName);            if (categoryColor) {                categoryPrefBranch.setCharPref(categoryNameFix, categoryColor);            } else {                try {                    categoryPrefBranch.clearUserPref(categoryNameFix);                } catch (ex) {                }            }        }        // If 'Overwrite' was chosen, delete category that was being edited        if (toBeDeleted != -1) {            list.selectedIndex = toBeDeleted;            this.deleteCategory();        }        this.updateCategoryList();    },
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/773aaa0f514e93183ab0cb524937e7f33cd7ef72/categories.js/buggy/calendar/base/content/preferences/categories.js