並且加上 log_tag.
所以看一下,是..
const char *args[5];
args[0] = "/system/bin/fsck_msdos";
args[1] = "-p";
args[2] = "-f";
args[3] = fsPath;
args[4] = NULL;
rc = logwrap(4, args, 1);
就是用 logwrap( ) 來呼叫。
vold 有實做自己的 logwrap( ), 就在 logwrapper.c
ref: http://developer.android.com/tools/debugging/debugging-log.html#viewingStd
另外,android 也可以把 stdout, stderr 重導到 logcat.
就是上面的說明。
$ adb shell stop $ adb shell setprop log.redirect-stdio true $ adb shell start
沒有留言:
張貼留言