摘要:
抄自http://beyondvincent.com/blog/2014/03/17/five-tips-for-using-self-signed-ssl-certificates-with-ios/ios7以后,inhouse安装需要ssl了,一般用商用的,不想用商用的,就自己弄一个,通过ope... 阅读全文
摘要:
先生成ssl证书openssl genrsa -out key.pem 2048openssl req -new -x509 -key key.pem -out cert.pem -days 1095然后,大概这样package mainimport ( "log" "net/http"... 阅读全文
摘要:
测试erlang脚本如下-module(empty).-author("mmc").%% API-export([test/1,test/0]).test()-> io:format("no arg~n").test(X)-> io:format("~p~n",[X]).编译,一种是进入erl,... 阅读全文
摘要:
不知从哪个版本开始,mac下的virtualbox建立vm以后,启动就提示什么驱动没有加载,google后,解决如下sudo /Library/Application\ Support/VirtualBox/LaunchDaemons/VirtualBoxStartup.sh restart 阅读全文
摘要:
package mainimport "fmt"type TestStruct struct {}func (object *TestStruct) test(msg string) { fmt.Println(msg)}type CallBack func(msg string)func c... 阅读全文
摘要:
找到CCDirector.h,找到void popScene();在下面加上一段类模板template void popSceneWithTransition(float t){ CCASSERT(_runningScene != nullptr, "running scene should ... 阅读全文
摘要:
如果数据库连接只有一个,在某个时间点(指的是某个及其短的时间内),多个读写的话,会出问题,修改了下,加了个mutex,算是解决了此问题,贴下备忘var mutex sync.Mutexfunc (c *Client) Do(args ...interface{}) ([]string, error)... 阅读全文
摘要:
package mainimport ( "fmt" "time")func deskGoRoutine(index int, userChannel chan string, deskChannel chan string) { for { fmt.Println(... 阅读全文
摘要:
由于某个需求,需要如题的转换,废话不多说,直接贴代码了,其实挺丑了,备用了func (this *Server) socketParserHandler(client *genTcpServer.Client, fullData []byte) { fmt.Println("original ... 阅读全文
摘要:
网上看到的,记录下,备用package mainimport ( "net/http")func main() { http.Handle("/", http.FileServer(http.Dir("./"))) http.ListenAndServe(":8080", nil)... 阅读全文