C
Chéraaar
Hi,
I have the following problem:
In one file (addresses) I have a bunch of lines like this:
New 0x8048240 Old 0x0: jne 804824a
New 0x8048253 Old 0x0: je 8048293
New 0x80482c7 Old 0x0: jp 80482e0
....
In another file (ranges) I have this:
[804820c-8048249]
[804824f-804826b]
[8048283-8048292]
....
I would like to do the following in C:
for each line in the addresses file (for example: New 0x8048240 Old 0x0: jne
804824a) I need to check if the first address (8048240) AND the second
address (804824a) is located in one of the ranges in the ranges file.(the 2
addresses may be situated in different ranges). Than I also need to count
them by sort of jump (for example: jne: 12 are good).
I've been messing around with fscanf and stuff like that but I ain't no good
at it... can someone help me plz.
Thank you in advance
Chéraaar
I have the following problem:
In one file (addresses) I have a bunch of lines like this:
New 0x8048240 Old 0x0: jne 804824a
New 0x8048253 Old 0x0: je 8048293
New 0x80482c7 Old 0x0: jp 80482e0
....
In another file (ranges) I have this:
[804820c-8048249]
[804824f-804826b]
[8048283-8048292]
....
I would like to do the following in C:
for each line in the addresses file (for example: New 0x8048240 Old 0x0: jne
804824a) I need to check if the first address (8048240) AND the second
address (804824a) is located in one of the ranges in the ranges file.(the 2
addresses may be situated in different ranges). Than I also need to count
them by sort of jump (for example: jne: 12 are good).
I've been messing around with fscanf and stuff like that but I ain't no good
at it... can someone help me plz.
Thank you in advance
Chéraaar