There is a better and quickly way to read a .txt file, find a Match string ?

So far I did it, but if I have more than 50.000 lines inside the txt file, it's going to take couple seconds to find that...

It would be better to break the 50,000 line file up into a series of much smaller files. 50 files with 1000 records can be scanned a lot faster than one 50,000 record file, if there is consistency as to which file (or small group of files) the record should be in.

Another possibility is to have the file contain ranges. The snippet you posted could be one record:
18429800 - 18429805
Then, read a record, until the / is encountered, parse it (to get the start and end tokens), and use strtoul() to get the values as numbers. Do the same for the target. Comparing numbers is faster than comparing strings.

Knowing something about the data is really necessary to offer good advice.