Move xdmeta() back to commands/xdump.c, internal linkage

Partially revert commit 4c746b5e.
This commit is contained in:
Markus Armbruster 2011-04-09 07:39:58 +02:00
parent 6db74cd282
commit af5e25aa16
3 changed files with 32 additions and 33 deletions

View file

@ -307,35 +307,3 @@ xdftr(struct xdstr *xd, int n)
else
xd->pr("/%d\n", n);
}
/*
* Dump meta-data for items of type TYPE to XD.
* Return RET_SYN when TYPE doesn't have meta-data, else RET_OK.
*/
int
xdmeta(struct xdstr *xd, int type)
{
struct castr *ca = ef_cadef(type);
int i;
int n = 0;
if (!ca)
return RET_SYN;
xdhdr(xd, ef_nameof(type), 1);
xdcolhdr(xd, ca);
for (i = 0; ca[i].ca_name; i++) {
if (ca[i].ca_flags & NSC_DEITY && !xd->divine)
continue;
if (ca[i].ca_flags & NSC_EXTRA)
continue;
xdflds(xd, mdchr_ca, &ca[i]);
xd->pr("\n");
n++;
}
xdftr(xd, n);
return RET_OK;
}