|
|
BSD 4.3reno
#include "quipu/util.h"
#include "quipu/attrvalue.h"
extern LLog * log_dsap;
static AV_Sequence eptr;
#define foreach(a) for(eptr = a; eptr != NULLAV; eptr = eptr->avseq_next)
AV_Sequence avs_comp_cpy (avs)
AV_Sequence avs;
{
AV_Sequence ptr;
if (avs==NULLAV) {
DLOG (log_dsap,LLOG_DEBUG,("copy of null avs"));
return (NULLAV);
}
ptr = (AV_Sequence) smalloc (sizeof(avseqcomp));
AttrV_cpy_aux (&avs->avseq_av,&ptr->avseq_av);
ptr->avseq_next = NULLAV;
return (ptr);
}
AV_Sequence avs_cpy (avs)
AV_Sequence avs;
{
AV_Sequence start;
AV_Sequence ptr,ptr2;
if (avs == NULLAV ) {
DLOG (log_dsap,LLOG_DEBUG,("avs_cpy of null avs"));
return (NULLAV);
}
start = avs_comp_cpy (avs);
ptr2 = start;
foreach (avs->avseq_next) {
ptr = avs_comp_cpy (eptr);
ptr2->avseq_next = ptr;
ptr2 = ptr;
}
return (start);
}
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.