The fread should return a string, not a object, but still i complains about not assing by reference. So it fixed, but not sure whether this may change some meaning?

Please double check this.