Skip to content

Instantly share code, notes, and snippets.

ea = BeginEA()
functions_with_assert = set()
function_renames = {}
for function_start in Functions(SegStart(ea), SegEnd(ea)):
function_name = GetFunctionName(function_start)
if not function_name.startswith('sub_'):
continue
function_end = FindFuncEnd(function_start)
ea = BeginEA()
functions_with_assert = set()
for function_start in Functions(SegStart(ea), SegEnd(ea)):
function_name = GetFunctionName(function_start)
if not function_name.startswith('sub_'):
continue
function_end = FindFuncEnd(function_start)
ea = BeginEA()
for function_start in Functions(SegStart(ea), SegEnd(ea)):
function_name = GetFunctionName(function_start)
if not function_name.startswith('sub_'):
continue
print function_name
### Keybase proof
I hereby claim:
* I am mopsled on github.
* I am alecg (https://keybase.io/alecg) on keybase.
* I have a public key whose fingerprint is 8FC2 54E7 0CD2 6054 1219 1141 E942 5868 8AB3 674F
To claim this, I am signing this object:
@mopsled
mopsled / utilities.h
Last active December 11, 2015 14:48
Drop-in fopen replacement for iOS applications that prepends the documents directory to file paths.
//
// utilities.h
//
#include <stdio.h>
#ifndef MyProject_utilities_h
#define MyProject_utilities_h
FILE *iosfopen(const char *filename, const char *mode);
@mopsled
mopsled / color.rb
Last active December 23, 2016 05:36
Simple Sinatra/ActiveRecord RESTful API
require 'active_record'
class Color < ActiveRecord::Base
end
module Jekyll
module Filters
def relative_date(date)
# Note: You can use ruby code outside of the module (see below)
relative_date_in_words(date)
end
end
end
# Adopted from a function found on stack overflow:
module Jekyll
module Filters
def my_filter(input)
"Filtered input: '#{input.upcase}'"
end
end
end
# Note: You can use any normal ruby library in your extenstion
require 'yaml'
module Jekyll
class YAMLToArray < Liquid::Tag
def initialize(tag_name, params, tokens)
super
@file, @variable = params.split(',', 2).map{ |x| x.strip }
end
puts "example number one"