node/lib/metasm/metasm/exe_format/shellcode_rwx.rb
def fixup_check(base_r=nil, base_w=nil, base_x=nil, bd={})
		if base_r.kind_of?(Hash)
			bd = base_r
			base_r = nil
		end
		@base_r = base_r if base_r
		@base_w = base_w if base_w
		@base_x = base_x if base_x
		fixup bd
		ed = EncodedData.new << @encoded_r << @encoded_w << @encoded_x
		raise ["Unresolved relocations:", ed.reloc.map { |o, r| "#{r.target} " + (Backtrace.backtrace_str(r.backtrace) if r.backtrace).to_s }].join("\n") if not ed.reloc.empty?
		self
	end
# resolve inter-section xrefs, raise if unresolved relocations remain
# call this when you have assembled+allocated memory for every section
resolve inter-section xrefs, raise if unresolved relocations remain
call this when you have assembled+allocated memory for every section
resolve inter - section xrefs raise if unresolved relocations remain call this when you have assembled + allocated memory for every section
def fixup_check(base_r=nil, base_w=nil, base_x=nil, bd={})
		if base_r.kind_of?(Hash)
			bd = base_r
			base_r = nil
		end
		@base_r = base_r if base_r
		@base_w = base_w if base_w
		@base_x = base_x if base_x
		fixup bd
		ed = EncodedData.new << @encoded_r << @encoded_w << @encoded_x
		raise ["Unresolved relocations:", ed.reloc.map { |o, r| "#{r.target} " + (Backtrace.backtrace_str(r.backtrace) if r.backtrace).to_s }].join("\n") if not ed.reloc.empty?
		self
	end
def fixup_check ( base_r = nil , base_w = nil , base_x = nil , bd = { } ) if base_r . kind_of? ( Hash ) bd = base_r base_r = nil end @base_r = base_r if base_r @base_w = base_w if base_w @base_x = base_x if base_x fixup bd ed = EncodedData . new << @encoded_r << @encoded_w << @encoded_x raise [ "Unresolved relocations:" , ed . reloc . map { | o , r | "#{r.target} " + ( Backtrace . backtrace_str ( r . backtrace ) if r . backtrace ) . to_s } ] . join ( "\n" ) if not ed . reloc . empty? self end
resolve inter-section xrefs, raise if unresolved relocations remain
call this when you have assembled+allocated memory for every section
resolve inter - section xrefs raise if unresolved relocations remain call this when you have assembled + allocated memory for every section
base_r
base_w
base_x
bd