Netatalk / netatalk

Netatalk is a Free and Open Source AFP fileserver. A *NIX or BSD system running Netatalk is capable of serving many Macintosh clients simultaneously as an AppleShare file server.
https://netatalk.io
GNU General Public License v2.0
354 stars 87 forks source link

Seems `bprint()` is only built if `DEBUG` is set. Looking at ``libatalk/util/bprint.c": #1696

Closed rdmark closed 3 weeks ago

rdmark commented 3 weeks ago

Seems bprint() is only built if DEBUG is set. Looking at ``libatalk/util/bprint.c":

#ifdef DEBUG

#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#include <atalk/util.h>

static const char       hexdig[] = "0123456789ABCDEF";

#define BPXLEN  50
#define BPALEN  18

void bprint( data, len )
...

But many files in libatalk/atp have a EBUG. For example libatalk/atp/atp_rsel.c. Looks suspiciously as a typo.

The offending call in fork.c is not wrapped in [D]EBUG... which means that maybe this only works if I build with DEBUG on. I'll try that, and the EBUG undefined will mean none of those DEBUG lines of code will kick in. Let's see.

Originally posted by @APCCV in https://github.com/Netatalk/netatalk/discussions/1694#discussioncomment-11064042