in reply to Re^2: Getting next line after matched one
in thread Getting next line after matched one

The problem with the approach you describe is that it won't work if two lines in a row match. For example, say you have a file like:
foo
bar
barbar
bell
and the pattern is /bar/. bar will match; if you read in the next line and print it out, you won't notice that barbar also matches, and so won't print out bell. You could add some code to fix this, but the flag approach handles it quite nicely.