Analyse the line of local resource of ``drbdadm status``

def _add_res(line):
    '''
    Analyse the line of local resource of ``drbdadm status``
    '''
    global resource
    fields = line.strip().split()

    if resource:
        ret.append(resource)
        resource = {}

    resource["resource name"] = fields[0]
    resource["local role"] = fields[1].split(":")[1]
    resource["local volumes"] = []
    resource["peer nodes"] = []