From 575bffe2804a7aac433102ee786b9f94ceaf1e27 Mon Sep 17 00:00:00 2001 From: Sebastian Hammer Date: Fri, 17 Feb 1995 14:41:13 +0000 Subject: [PATCH] Added simple display of records. --- kernel/default.res | 4 ++-- kernel/urp.c | 17 ++++++++++++++++- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/kernel/default.res b/kernel/default.res index 7e79300..a7a35d3 100644 --- a/kernel/default.res +++ b/kernel/default.res @@ -1,11 +1,11 @@ # Email gateway - general kernel resources -# $Id: default.res,v 1.4 1995/02/17 09:08:36 adam Exp $ +# $Id: default.res,v 1.5 1995/02/17 14:41:13 quinn Exp $ # # Important directories, programs, etc. gw.reply.mta: /usr/bin/smail gw.reply.tmp.prefix: gwr gw.reply.tmp.dir: /tmp -gw.path: /home/adam/egate/kernel +gw.path: /home/quinn/egate/kernel # Target definitions gw.portno: 2000 diff --git a/kernel/urp.c b/kernel/urp.c index 308b93b..29b0e62 100644 --- a/kernel/urp.c +++ b/kernel/urp.c @@ -2,7 +2,10 @@ * Europagate, 1995 * * $Log: urp.c,v $ - * Revision 1.5 1995/02/17 14:22:13 adam + * Revision 1.6 1995/02/17 14:41:14 quinn + * Added simple display of records. + * + * Revision 1.5 1995/02/17 14:22:13 adam * First steps of CCL show command. Not finished yet. * * Revision 1.4 1995/02/17 09:08:36 adam @@ -31,6 +34,7 @@ #include #include "kernel.h" +#include #define LINE_MAX 256 @@ -258,6 +262,7 @@ static int exec_base (struct ccl_token *list) static int exec_show (struct ccl_token *list) { const struct zass_presentent *zp; + zass_record *pp; char num_str[20]; int num; @@ -274,6 +279,16 @@ static int exec_show (struct ccl_token *list) return -3; gw_log (GW_LOG_DEBUG, "urp", "zass_present of %d records", num); zp = zass_present(info.zass, "Default", 1, num); + if (zp) + { + fprintf(reply_fd, "Got %d records\n", zp->num); + for (pp = zp->records; pp; pp = pp->next) + { + Iso2709Rec p = iso2709_cvt(pp->record); + iso2709_display(p, reply_fd); + iso2709_rm(p); + } + } return 0; } -- 1.7.10.4