2024年3月25日

vs2017代码运行位置与断点位置不一致

摘要: 尝试1:clean重编,失败 尝试2:修改部分代码 比如随便添加一个int a= 1;无意义的一行,失败 尝试3:把代码全部删除重新拉取。 失败 尝试4:重启 失败 尝试5:文件删了重新写 失败 最终原因是visual studio里文件file太大。导致断点行数对不上。 阅读全文

posted @ 2024-03-25 15:32 对我不好 阅读(10) 评论(0) 推荐(0) 编辑

2024年2月5日

实际游戏项目中遇到的一些坑爹bug

摘要: 1. class、struct里的数据未正确初始化导致bug。 2.proto 2 声明数据时需要加[default = 0] 否则proto里的数据有可能随机找一个内存进行设值。 阅读全文

posted @ 2024-02-05 15:38 对我不好 阅读(2) 评论(0) 推荐(0) 编辑

2024年2月1日

c++单例模式实现

摘要: class noncopyable { public: noncopyable(const noncopyable&) = delete; noncopyable& operator=(const noncopyable&) = delete; noncopyable() = default; ~n 阅读全文

posted @ 2024-02-01 16:03 对我不好 阅读(1) 评论(0) 推荐(0) 编辑

字节对齐的方式

摘要: (nsize + 4096) & ~4096 size + 4095:首先将 size 加上 4095,这样就可以确保在原本的 size 基础上,至少增加了4095个字节。 & ~4095:然后使用按位与操作符 & 结合取反操作 ~,这样会将 size + 4095 的结果向下舍入到最接近的4096 阅读全文

posted @ 2024-02-01 11:18 对我不好 阅读(9) 评论(0) 推荐(0) 编辑

2024年1月16日

完成端口API整理

摘要: 1. BOOL GetQueuedCompletionStatus( HANDLE CompletionPort, LPDWORD lpNumberOfBytesTransferred, PULONG_PTR lpCompletionKey, LPOVERLAPPED *lpOverlapped, 阅读全文

posted @ 2024-01-16 11:31 对我不好 阅读(2) 评论(0) 推荐(0) 编辑

2023年9月21日

Cannot initiate the connection to cn.archive.ubuntu.com:80 (2403:2c80:5::6). - connect (101: Network is unreachable)

摘要: 版本:ubuntu 22.04 Cannot initiate the connection to cn.archive.ubuntu.com:80 (2403:2c80:5::6). - connect (101: Network is unreachable) 嗯,被墙了。找到 /etc/apt 阅读全文

posted @ 2023-09-21 22:46 对我不好 阅读(1031) 评论(0) 推荐(0) 编辑

2023年9月19日

core文件输出位置改变

摘要: 切换到root用户 echo '/tmp/core_%e.%p' >/proc/sys/kernel/core_pattern "tmp"是要输出的目录 阅读全文

posted @ 2023-09-19 17:51 对我不好 阅读(5) 评论(0) 推荐(0) 编辑

2023年8月24日

mysql启动以后无法看到监听端口号非常怪异

摘要: 配置如下[mysqld]bind-address=0.0.0.0port=3309datadir=/usr/local/mysql8025/databasedir=/usr/local/mysql8025socket=/usr/local/mysql8025/data/mysql.socklog-e 阅读全文

posted @ 2023-08-24 10:20 对我不好 阅读(36) 评论(0) 推荐(0) 编辑

2023年8月23日

Custom ASAN_OPTIONS set without abort_on_error=1

摘要: background: when i want to run AFL . I met this issue. and either set export ASAN_OPTIONS=abort_on_error=0 nor export ASAN_OPTIONS=abort_on_error=1 do 阅读全文

posted @ 2023-08-23 13:59 对我不好 阅读(40) 评论(0) 推荐(0) 编辑

2023年8月22日

kylin操作系统安装mysql

摘要: 首先坑的是麒麟说自己基于ubuntu。结果包管理工具用的yum。然后yum包里还没有mysql只能自己下载安装。 1.第一种方式直接下MySQL :: Download MySQL Community Server (Archived Versions) 里装好的mysql的tar包,然后解压。解压 阅读全文

posted @ 2023-08-22 14:38 对我不好 阅读(234) 评论(0) 推荐(0) 编辑

导航