'Remove one or more messages -- may raise os.error.'

def removemessages(self, list):

    errors = []
    deleted = []
    for n in list:
        path = self.getmessagefilename(n)
        commapath = self.getmessagefilename((',' + str(n)))
        try:
            os.unlink(commapath)
        except os.error:
            pass
        try:
            os.rename(path, commapath)
        except os.error as msg:
            errors.append(msg)
        else:
            deleted.append(n)
    if deleted:
        self.removefromallsequences(deleted)
    if errors:
        if (len(errors) == 1):
            raise os.error, errors[0]
        else:
            raise os.error, ('multiple    errors:', errors)
