Skip to content
Snippets Groups Projects
Commit b46af7c2 authored by rswindell's avatar rswindell
Browse files

Moved remove_ctrl_a() from qwk.cpp to str.cpp (and DLL-exported).

parent d1ba0c5f
Branches
Tags
No related merge requests found
......@@ -39,29 +39,6 @@
#include "post.h"
#include "qwk.h"
/****************************************************************************/
/* Removes ctrl-a codes from the string 'instr' */
/****************************************************************************/
char* remove_ctrl_a(char *instr, char *outstr)
{
char str[512],*p;
uint i,j,k;
j=strlen(instr);
for(k=i=0;i<j;i++) {
if(instr[i]==1)
i++;
else str[k++]=instr[i]; }
str[k]=0;
if(outstr!=NULL)
p=outstr;
else
p=instr;
strcpy(p,str);
return(p);
}
/****************************************************************************/
/* Converts a long to an msbin real number. required for QWK NDX file */
/****************************************************************************/
......
......@@ -41,6 +41,28 @@ const char *wday[]={"Sun","Mon","Tue","Wed","Thu","Fri","Sat"};
const char *mon[]={"Jan","Feb","Mar","Apr","May","Jun"
,"Jul","Aug","Sep","Oct","Nov","Dec"};
/****************************************************************************/
/* Removes ctrl-a codes from the string 'instr' */
/****************************************************************************/
char* DLLCALL remove_ctrl_a(char *instr, char *outstr)
{
char str[1024],*p;
uint i,j,k;
j=strlen(instr);
for(k=i=0;i<j;i++) {
if(instr[i]==1)
i++;
else str[k++]=instr[i]; }
str[k]=0;
if(outstr!=NULL)
p=outstr;
else
p=instr;
strcpy(p,str);
return(p);
}
/****************************************************************************/
/* Lists all users who have access to the current sub. */
/****************************************************************************/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment