使用GoLang在windows下连接数据库dial tcp: GetAddrInfoW: The specified class was not found

使用GoLang在windows下连接数据库dial tcp: GetAddrInfoW: The specified class was not found

            dial tcp: GetAddrInfoW: The specified class was not found

在数据库连接进出现这个异常,搜来搜去,没找到什么合适的办法,在QQ群中也没人响应,所以就自己再查查,似乎是在进行连接时,要调用windows的api GetAddrInfoW失败了,所以就查自己的配置文件格式,发现是utf-8无BOM,windows模式存的,于是试着换成utf-8 - BOM,UNIX模式,于是解决了。

上海老李,QQ:1354608370,FreeSWITCH QQ群: