X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=flower%2Ftext-stream.cc;h=9c87211c252e02ff06cf9f9c60733936cff49731;hb=38ec7508357499b6bcf78a2cf0e825caac27a591;hp=f9a8307226bcaf03fdaed9d45feb4a02152d3aa2;hpb=1edc2436a028cb2d1be8786ab0972a95b0985d42;p=lilypond.git diff --git a/flower/text-stream.cc b/flower/text-stream.cc index f9a8307226..9c87211c25 100644 --- a/flower/text-stream.cc +++ b/flower/text-stream.cc @@ -3,30 +3,39 @@ Text_stream::Text_stream (String fn) { ios::sync_with_stdio(); - if (fn == "") - { - name = ""; - f = stdin; - } - - else - { - name = fn; - f = fopen (fn.ch_C (), "r"); - } - - if (!f) - { - cerr <<__FUNCTION__<< ": can't open `" << fn << "'\n"; - exit (1); - } + if (fn == "") + { + name = _ (""); + f = stdin; + } + + else + { + name = fn; + f = fopen (fn.ch_C (), "r"); + } - line_no = 1; + if (!f) + { + cerr << __FUNCTION__ + << ": " << _f ("can't open file: `%s'", fn) << '\n'; + exit (1); } + line_no = 1; +} + void Text_stream::message (String s) { - cerr << "\n"<