Пример #1
0
def walk(data, arg):
    """
    Nice formatted aggregate walker.
    """
    tmp = data.contents.dtada_data

    name = cast(tmp + 16, c_char_p).value
    count = deref(tmp + 272, c_int).value

    print 'Zone "{0:s}" made {1:d} syscalls.'.format(name, count)

    return 0
Пример #2
0
def walk(data, arg):
    '''
    Nice formatted aggregate walker.
    '''
    tmp = data.contents.dtada_data

    name = cast(tmp + 16, c_char_p).value
    count = deref(tmp + 272, c_int).value

    print 'Zone "{0:s}" made {1:d} syscalls.'.format(name, count)

    return 0
def my_walk(data, arg):
    """
    Aggregate walker.

    Have a look at the simple walk func in the consumer source code...
    """
    tmp = data.contents.dtada_data
    name = cast(tmp + 16, c_char_p).value
    instance = deref(tmp + 272, c_int).value

    print '{0:4d} > {1:60s}'.format(instance, name)

    return 0
def my_walk(data, arg):
    '''
    Aggregate walker.

    Have a look at the simple walk func in the consumer source code...
    '''
    tmp = data.contents.dtada_data
    name = cast(tmp + 16, c_char_p).value
    instance = deref(tmp + 272, c_int).value

    print '{0:4d} > {1:60s}'.format(instance, name)

    return 0