|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 424 (0x1a8)
Types: TextFile
Names: »trimcpy.c«
└─⟦9ae75bfbd⟧ Bits:30007242 EUUGD3: Starter Kit
└─⟦3658e588a⟧ »EurOpenD3/mail/mh/mh-6.7.tar.Z«
└─⟦c75e36ecb⟧
└─⟦this⟧ »mh-6.7/sbr/trimcpy.c«
/* trimcpy.c - strip [lt]wsp and replace newlines with spaces */
#include "../h/mh.h"
#include <ctype.h>
#include <stdio.h>
char *trimcpy (cp)
register char *cp;
{
register char *sp;
while (isspace (*cp))
cp++;
for (sp = cp + strlen (cp) - 1; sp >= cp; sp--)
if (isspace (*sp))
*sp = NULL;
else
break;
for (sp = cp; *sp; sp++)
if (isspace (*sp))
*sp = ' ';
return getcpy (cp);
}