mirror of
https://gitee.com/openharmony/developtools_hiperf
synced 2024-11-23 07:29:42 +00:00
update
Signed-off-by: zhangcui <zhangcui11@huawei.com>
This commit is contained in:
parent
56b3befcd1
commit
65e4d1a18c
@ -193,9 +193,16 @@ class GetLibFiles(object):
|
||||
if os.path.isfile(file_path):
|
||||
os.remove(file_path)
|
||||
if self.hdc.switch_root():
|
||||
os.system('hdc shell cat /proc/sys/kernel/kptr_restrict > tmp.txt')
|
||||
file_object = open('./tmp.txt','r')
|
||||
text = file_object.read()
|
||||
file_object.close()
|
||||
os.remove('./tmp.txt')
|
||||
self.hdc.run_hdc_cmd(['shell',
|
||||
'"echo 0 >/proc/sys/kernel/kptr_restrict"'])
|
||||
self.hdc.run_hdc_cmd(['file recv', '/proc/kallsyms', file_path])
|
||||
self.hdc.run_hdc_cmd(['shell',
|
||||
'"echo ' + text[0] + ' >/proc/sys/kernel/kptr_restrict"'])
|
||||
|
||||
|
||||
def main():
|
||||
|
Loading…
Reference in New Issue
Block a user