Giter Site home page Giter Site logo

Support Unicode in paths about glog HOT 6 OPEN

xfc1939 avatar xfc1939 commented on June 2, 2024
Support Unicode in paths

from glog.

Comments (6)

sergiud avatar sergiud commented on June 2, 2024

Your path contains the Unicode character U+00A0 in terms of a UTF-8 code point. AFAIK Windows does not support UTF-8 encoding for path specification in general. If this is still true, such a path would be indeed invalid.

from glog.

xfc1939 avatar xfc1939 commented on June 2, 2024

For non-English countries, it's very common that the path contains Unicode. I have checked the source code and found that the _open function cannot work correctly. Replacing it with _wopen may be a good choice.

from glog.

sergiud avatar sergiud commented on June 2, 2024

Replacing ANSI function variants by their Unicode counterparts is not sufficient. The path handling in environment variables, flags etc. must also be completely reworked.

from glog.

xfc1939 avatar xfc1939 commented on June 2, 2024

Support Unicode in paths #998

from glog.

sergiud avatar sergiud commented on June 2, 2024

Thanks! #786 seems to be related.

from glog.

xfc1939 avatar xfc1939 commented on June 2, 2024

Thanks! #786 seems to be related.

The solution from #786 cannot resolve this question. it works if I set FLAGS_log_dir to a unicode path,but It cannot work when the path contains the Unicode character 0xc2a0. for example: log dir

from glog.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.