📄 salloc.h
字号:
#ifndef SALLOC_H#define SALLOC_H#include <stdlib.h>extern void *safe_malloc(size_t size); /* Does malloc(size) with null-pointer check. * Deallocate with free(). */extern void *safe_realloc(void *ptr, size_t size); /* Does realloc(ptr, size) with null-pointer check. * Deallocate with free(). */extern char *safe_strdup(const char *string); /* Returns a copy of string with null-pointer check. * Deallocate with free(). */#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -