Fix double fclose() if clear() is called before the destructor

The important part is `stdOutIsMine_ = false;` after the `fclose(trueStdOut_)`, but the asserts are there to be sure that the owner of `trueStdOut_ is really the `owner_` as it should.

Without it, i get crashes in MultiDimFit in some cases.

Will then merge in SL6 as well.