摘要: 1. 华蓓老师主页 http://staff.ustc.edu.cn/~bhua/ 2. OSI vs TCP/IP 3. TCP header 4. TCP流量控制 1)连接建立时,接收端告诉发送端接收窗口的数值rwnd=400byte 2) 如果发生丢包,接收端回给发送端的ack字段设为1, a 阅读全文
posted @ 2016-05-23 23:06 AndyHu518 阅读(187) 评论(0) 推荐(0) 编辑
摘要: #include <sys/socket.h> 1. int socket(int domain, int type, int protocol) socket: return fd domain: AF_INET(IPv4), AF_INET6(IPv6) type: SOCK_DGRAM(udp 阅读全文
posted @ 2016-05-23 22:50 AndyHu518 阅读(1238) 评论(0) 推荐(0) 编辑
摘要: 1.查看各种目标文件的结构和内容 objdump -h SimpleSection.o 2.查看ELF文件代码段、数据段、BSS(Block Stated by Symbol)段的长度 size SimpleSection.o 注解: 程序源码被编译后主要分成两种段:程序指令和程序数据。 代码段属于 阅读全文
posted @ 2016-05-23 22:46 AndyHu518 阅读(334) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2016-05-23 22:41 AndyHu518 阅读(124) 评论(0) 推荐(0) 编辑
摘要: 0. ln -s src_dir //一个参数即可在当前目录下生成一个软链接 1.git command --clone/push a branch git clone <url> --branch <branch> --single-branch [<folder>] git push remot 阅读全文
posted @ 2016-05-23 22:40 AndyHu518 阅读(548) 评论(0) 推荐(0) 编辑
摘要: 本人跟web无缘,从来没有想去学http,现在看来,学学也是有益无害,总会要用着点滴。 RFC见这里: https://www.ietf.org/rfc/rfc2616.txt 0. URI格式 http://host[:port][abs_path] 1. Message Type (Reques 阅读全文
posted @ 2016-05-23 16:24 AndyHu518 阅读(1054) 评论(0) 推荐(0) 编辑
摘要: 1. Hello, World #import <Foundation/Foundation.h> int main() 2. Block(本质是匿名函数,类似C的函数指针, JS closure, C++11的Lambda functions) (1) example: NSLog(@"sum i 阅读全文
posted @ 2016-05-18 12:43 AndyHu518 阅读(271) 评论(0) 推荐(0) 编辑
摘要: //Test write json Json::Value rooter; Json::FastWriter w; rooter["isTest"] = false; rooter["isAndy"] = true; std:string json_string = w.write(rooter); 阅读全文
posted @ 2016-05-17 16:12 AndyHu518 阅读(149) 评论(0) 推荐(0) 编辑
摘要: 原文链接:http://www.yiibai.com/redis/redis_quick_guide.html1.启动Redis $redis-server2. 检查Redis是否在工作$redis-cli3.Redis的5种数据类型 :字符串,哈希,列表,集合,有序集合例子: 1)字符串redis 阅读全文
posted @ 2016-02-28 23:43 AndyHu518 阅读(199) 评论(0) 推荐(0) 编辑
摘要: XMPP - Extensible Messaging and Presence Protocol 1. 中文版3920 http://wiki.jabbercn.org/RFC3920 2. 大部分客户端通过 TCP 连接直接连到服务器,并通过XMPP获得由服务器以及联合服务器所提供的全部功能。多 阅读全文
posted @ 2016-02-28 02:57 AndyHu518 阅读(234) 评论(0) 推荐(0) 编辑