Browse Source

Have peek command honor "tagfocus"

The peek command allows looking at details of a function, and it
avoids any trimming to provide full details. However, when using
tagfocus it is useful to still limit to the filtered samples.
With this change peek will honor tagfocus, but it will avoid any
other trimming.
Raul Silvera 9 years ago
parent
commit
9472279cde
1 changed files with 4 additions and 2 deletions
  1. 4
    2
      internal/driver/driver.go

+ 4
- 2
internal/driver/driver.go View File

124
 }
124
 }
125
 
125
 
126
 func applyCommandOverrides(cmd []string, v variables) variables {
126
 func applyCommandOverrides(cmd []string, v variables) variables {
127
-	trim, focus, hide := v["trim"].boolValue(), true, true
127
+	trim, focus, tagfocus, hide := v["trim"].boolValue(), true, true, true
128
 
128
 
129
 	switch cmd[0] {
129
 	switch cmd[0] {
130
 	case "proto", "raw":
130
 	case "proto", "raw":
131
-		trim, focus, hide = false, false, false
131
+		trim, focus, tagfocus, hide = false, false, false, false
132
 		v.set("addresses", "t")
132
 		v.set("addresses", "t")
133
 	case "disasm", "weblist":
133
 	case "disasm", "weblist":
134
 		trim = false
134
 		trim = false
155
 	if focus == false {
155
 	if focus == false {
156
 		v.set("focus", "")
156
 		v.set("focus", "")
157
 		v.set("ignore", "")
157
 		v.set("ignore", "")
158
+	}
159
+	if tagfocus == false {
158
 		v.set("tagfocus", "")
160
 		v.set("tagfocus", "")
159
 		v.set("tagignore", "")
161
 		v.set("tagignore", "")
160
 	}
162
 	}