[kgtp] r1004 committed - Update query to make it more clear

  • From: kgtp@xxxxxxxxxxxxxx
  • To: kgtp@xxxxxxxxxxxxx
  • Date: Fri, 30 Mar 2012 02:15:19 +0000

Revision: 1004
Author:   teawater
Date:     Thu Mar 29 19:14:42 2012
Log:      Update query to make it more clear

http://code.google.com/p/kgtp/source/detail?r=1004

Modified:
 /trunk/add-ons/hotcode.py

=======================================
--- /trunk/add-ons/hotcode.py   Thu Mar 29 17:44:16 2012
+++ /trunk/add-ons/hotcode.py   Thu Mar 29 19:14:42 2012
@@ -89,7 +89,7 @@
 def sigint_handler(num, e):
        hotcode_show()
        try:
-               s = raw_input('Continue? (yes)')
+               s = raw_input('Conitnue? [(y)es], (n)o:')
        except:
                s = 'y'
        finally:
@@ -126,9 +126,9 @@
 trace_user = True
 trace_kernel = True
 while 1:
-       tmp = "Both"
+       tmp = "both"
        try:
-               tmp = raw_input('Which part of code you want 
trace?(User/Kernel/[Both])')
+ tmp = raw_input('Which part of code you want trace? [(b)oth], (u)ser, (k)ernel:')
        except:
                continue
        if tmp[0:1] == 'U' or tmp[0:1] == 'u':
@@ -138,12 +138,12 @@
        break

 #Get which task pid why want to trace
-print("Please input the pid of task that you want to trace - one per line (use empty to end input).")
-print("If not set any task, will trace all code in the Kernel.")
+print("Please input the pid of task that you want to trace - one per line.")
+print("If not set any task, will trace all code in the Linux kernel.")
 while 1:
        pid = -1
        try:
-               pid = input('id:')
+               pid = input('task pid (use empty to stop pid input):')
        except:
                pass
        if pid <= 0:
@@ -166,7 +166,7 @@
                while 1:
                        tmp = ""
                        try:
- tmp = raw_input('Please input the debug binary of task if you want to change it:['+user_dir+']') + tmp = raw_input('Please input the debug binary of task if you want to change it ['+user_dir+']:')
                        except:
                                continue
                        if tmp != "":
@@ -257,7 +257,7 @@
 def get_ignore_str(function):
        ret = ""
        try:
-               s = raw_input('Do you want to ignore function \"'+function+'\"? 
(yes)')
+ s = raw_input('Do you want to ignore function \"'+function+'\"? [(y)es], (n)o:')
        except:
                s = 'y'
        if s[0:1] != 'n' and s[0:1] != 'N':
@@ -279,7 +279,7 @@
        no_task = True

 try:
- show_line_number = input('Show line number (0 meas all)?['+str(show_line_number)+']') + show_line_number = input('Show line number (0 meas all)? ['+str(show_line_number)+']:')
 except:
        show_line_number = show_line_number_default

@@ -415,7 +415,7 @@

 if trace_kernel:
        try:
-               s = raw_input('Do you load the symbol from LKM? [no]')
+               s = raw_input('Do you load the symbol from LKM? (y)es, [(n)o]:')
        except:
                s = 'n'
        if s[0:1] == 'y' or s[0:1] == 'Y':

Other related posts:

  • » [kgtp] r1004 committed - Update query to make it more clear - kgtp