Skip to content

Commit

Permalink
Win32: use the ISO C and C++ conformant name "_putenv" instead of dep…
Browse files Browse the repository at this point in the history
…recated "putenv"
  • Loading branch information
zdenop committed Sep 28, 2018
1 parent a0564fd commit abe40f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/training/pango_font_info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ void PangoFontInfo::HardInitFontConfig(const std::string& fonts_dir,
#ifdef _WIN32
std::string env("FONTCONFIG_PATH=");
env.append(cache_dir_.c_str());
putenv(env.c_str());
putenv("LANG=en_US.utf8");
_putenv(env.c_str());
_putenv("LANG=en_US.utf8");
#else
setenv("FONTCONFIG_PATH", cache_dir_.c_str(), true);
// Fix the locale so that the reported font names are consistent.
Expand Down

0 comments on commit abe40f1

Please sign in to comment.