Skip to content

Commit

Permalink
change a couple of variables to camel case
Browse files Browse the repository at this point in the history
  • Loading branch information
justinfenn committed Oct 4, 2015
1 parent cdc3eae commit 7ce7526
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions poke.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,24 @@ import "syscall"

func main() {
pid := getPid()
search_val := getSearchVal()
searchVal := getSearchVal()
attachToProcess(pid)
matchingAddresses := searchRegions(search_val, pid)
matchingAddresses := searchRegions(searchVal, pid)
detach(pid)
for len(matchingAddresses) > 1 {
fmt.Println("num matches:", len(matchingAddresses))
//resumeTracee(pid)
search_val = getSearchVal()
searchVal = getSearchVal()
// TODO can we resume easily, or should we just detach/reattach every time?
attachToProcess(pid)
matchingAddresses = searchOldMatches(search_val, matchingAddresses, pid)
matchingAddresses = searchOldMatches(searchVal, matchingAddresses, pid)
detach(pid)
}
if len(matchingAddresses) == 1 {
fmt.Println("found a single match!")
replace_val := getReplacementValue()
replaceVal := getReplacementValue()
attachToProcess(pid)
pokeData(pid, replace_val, matchingAddresses[0])
pokeData(pid, replaceVal, matchingAddresses[0])
detach(pid)
} else {
fmt.Println("no matches found")
Expand Down

0 comments on commit 7ce7526

Please sign in to comment.