def get_ssid(_, data):
converted = list()<EOL>for i in range(len(data)):<EOL><INDENT>try:<EOL><INDENT>c = unichr(data[i])<EOL><DEDENT>except NameError:<EOL><INDENT>c = chr(data[i])<EOL><DEDENT>if unicodedata.category(c) != '<STR_LIT>' and c not in ('<STR_LIT:U+0020>', '<STR_LIT:\\>'):<EOL><INDENT>converted.append(c)<EOL><DEDENT>elif c == '<STR_LIT>':<EOL><INDENT>converted.append(c)<EOL><DEDENT>elif c == '<STR_LIT:U+0020>' and i not in (<NUM_LIT:0>, len(data)):<EOL><INDENT>converted.append('<STR_LIT:U+0020>')<EOL><DEDENT>else:<EOL><INDENT>converted.append('<STR_LIT>'.format(data[i]))<EOL><DEDENT><DEDENT>return '<STR_LIT>'.join(converted)<EOL>
http://git.kernel.org/cgit/linux/kernel/git/jberg/iw.git/tree/util.c?id=v3.17#n313.

    Positional arguments:
    data -- bytearray data to read.

    Returns:
    String.