]> git.donarmstrong.com Git - lilypond.git/blobdiff - flower/text-stream.cc
release: 1.3.91
[lilypond.git] / flower / text-stream.cc
index 9c87211c252e02ff06cf9f9c60733936cff49731..446c44a01917bccf55f1ec6889791f6ec92d64b3 100644 (file)
@@ -1,3 +1,5 @@
+#include <stdlib.h>
+#include <iostream.h>
 #include "text-stream.hh"
 
 Text_stream::Text_stream (String fn)
@@ -39,3 +41,11 @@ Text_stream::eof_b ()
       // !pushback.size () && 
       feof (f);
 }
+
+Text_stream::~Text_stream()
+{
+    if (!eof_b()) 
+      cerr <<__FUNCTION__<< ": closing unended file";
+    
+    fclose (f);
+  }