Fixed!  Thanks.

Patrick

   Screwed up the patch sent by Henrik Edlund <[EMAIL PROTECTED]>.  It should
    have been:
    >     for(i = 0; i < listv.count; ++i ){
    >         s = listv.list[i];
    > -       if( (t = safestrpbrk(s,File_sep)) ) *t++ = 0;
    > +       if( (t = safestrpbrk(s,Value_sep)) ) *t++ = 0;
    >         Free_line_list(&l);
    > -       Split(&l,t,Value_sep,0,0,0,0,0,0);
    > +       Split(&l,t,File_sep,0,0,0,0,0,0);
    >         DEBUGF(DLPQ1)("Job_status: Force_lpq_status '%s'='%s'", s,t);
  (Correction by: Henrik Edlund <[EMAIL PROTECTED]>)

   Misimplemented Hendriks accounting fixes.
    -    if( Match_ipaddr_value(&l,&RemoteHost_IP) ){
    +    if( Match_ipaddr_value(&l,&RemoteHost_IP) == 0 ){
   Oooops.
  (Correction by: Henrik Edlund <[EMAIL PROTECTED]>)



> From [EMAIL PROTECTED] Fri Oct 10 12:46:47 2003
> Date: Fri, 10 Oct 2003 21:46:38 +0200 (CEST)
> From: Henrik Edlund <[EMAIL PROTECTED]>
> To: Patrick Powell <[EMAIL PROTECTED]>
> Cc: [EMAIL PROTECTED]
> Subject: Bug in accounting_namefixup implementation in LPRng 3.8.22
>
> This feature was added in 3.8.22, in a differerent way that I originally
> implemented it in the patches I sent.
>
> But when you did this reimplementation, a small bug sneaked in. You forgot
> a "== 0" which makes the if-statement mean "if not match", when it should
> be "if match". This gives it some very undesirable and dangerous behaviour
> as one end up with totally different accounting names than one wanted. The
> patch below to getqueue.c fixes this:
>
>
>                         Free_line_list(&l);
>                         DEBUG1("Create_control: hostlist '%s'", s );
>                         Split(&l,s,",",0,0,0,0,0,0);
> -                       if( Match_ipaddr_value(&l,&RemoteHost_IP) ){
> +                       if( Match_ipaddr_value(&l,&RemoteHost_IP) == 0 ){
>                                 Free_line_list(&l);
>                                 DEBUG1("Create_control: match, using users  '%s'", t 
> );
>                                 Split(&l,t,",",0,0,0,0,0,0);
>
>


-----------------------------------------------------------------------------
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:                           | example:
subscribe LIST <mailaddr>       |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST <mailaddr>     |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-----------------------------------------------------------------------------

Reply via email to