Skip to content

Instantly share code, notes, and snippets.

@CuberL
CuberL / method_factory.go
Created March 26, 2018 05:45
[方法工厂模式] 方法工厂模式 #golang #设计模式
package main
@CuberL
CuberL / config
Created November 22, 2018 04:13
sendsms
AccessKeyId LTAIL****N6gpzW6
SignatureVersion 1.0
SignatureMethod HMAC-SHA1
Format JSON
Action SendSms
Version 2017-05-25
RegionId cn-hangzhou
SignName ****
TemplateCode ****
@CuberL
CuberL / c
Created April 22, 2020 05:42
problem in tbox http client
#include "tbox/tbox.h"
int main() {
tb_init(tb_null, tb_null);
int i = 10;
while (i --> 1) {
tb_http_ref_t http = tb_http_init();
tb_http_ctrl(http, TB_HTTP_OPTION_SET_COOKIES, tb_cookies());
tb_http_ctrl(http, TB_HTTP_OPTION_SET_METHOD, TB_HTTP_METHOD_GET);
tb_http_ctrl(http, TB_HTTP_OPTION_SET_URL, "http://google.com");