Created
December 5, 2013 05:47
-
-
Save tanb/7800671 to your computer and use it in GitHub Desktop.
~/.lldbinitです
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
script import os, sys | |
# So that ~/lldbutils.py takes precedence. | |
script sys.path[:0] = [os.path.expanduser('~')] | |
script import lldbutils | |
command script add -f lldbutils.print_data_as_string_function pdas |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 | |
import lldb | |
def print_data_as_string_function(debugger, command, result, internal_dict): | |
cmd = "expr (void)NSLog(@\"%@\", (NSString *)[[NSString alloc] initWithData:"+ command +" encoding:4])" | |
lldb.debugger.HandleCommand(cmd) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
こんなかんじで
(lldb) pdas operation.request.HTTPBody
2013-12-05 14:42:59.865 hoge[18510:70b] hogehoge