⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 strsep.c

📁 自己移植的linux下的流媒体播放器原代码,支持mms协议,支持ftp和http协议.
💻 C
字号:
/* strsep implementation for systems that do not have it in libc */#include <stdio.h>#include <string.h>#include "../config.h"#ifndef HAVE_STRSEPchar *strsep(char **stringp, const char *delim) {  char *begin, *end;  begin = *stringp;  if(begin == NULL)    return NULL;  if(delim[0] == '\0' || delim[1] == '\0') {    char ch = delim[0];    if(ch == '\0')      end = NULL;    else {      if(*begin == ch)        end = begin;      else if(*begin == '\0')        end = NULL;      else        end = strchr(begin + 1, ch);    }  }  else    end = strpbrk(begin, delim);  if(end) {    *end++ = '\0';    *stringp = end;  }  else    *stringp = NULL;   return begin;}#endif

⌨️ 快捷键说明

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