saltstack/salt — pull request #18682 by eliasp (2014-12-03 18:32:45+00:00)
Title: Don't empty the file when it is supposed to be only read.

Iterating over an `fileinput.input()` object with `inplace=True`
and not returning any results per iteration leaves an empty
input file.

Solves #18680