[Nut-upsdev] Default NUT PORT

Charles Lepple clepple at gmail.com
Sun Jan 14 00:42:32 CET 2007


On 1/13/07, Arjen de Korte <nut+devel at de-korte.org> wrote:
> In my latest patch, I hardcoded the port NUT uses for TCP communication
> (3493). The reason is, that I can't figure out a way how to change the
> numeric value of the #define'd PORT into a character string. Using
> snprintf() and a temporary buffer just seems wrong, since this should be
> handled by the preprocessor, rather than at runtime.

I see the 'QUOTED' macro defined in conf.c and upsd.c, but it doesn't
look like it is being used. That should work, no? Or is this only
permissible in certain versions of the C standard?

-- 
- Charles Lepple



More information about the Nut-upsdev mailing list