stripfx.c

来自「dos 1.0 其中包含quick basic源代码、内存管理himem emm」· C语言 代码 · 共 23 行

C
23
字号
#include <stdlib.h>
#include <string.h>

#include "strpfx.h"

// Determine if a string is a prefix
// - case insensitive variant

char*
striprefix (
    char* szTest,
    char* szFull )
{
    int cch = strlen ( szTest );

    // if no match, return NULL
    if ( strnicmp ( szTest, szFull, cch ))
	return NULL;

    // success.  return where prefix failed
    return szFull + cch;
    }

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?