1/* MiniUPnP project 2 * http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/ 3 * author: Ryan Wagoner 4 * (c) 2006 Thomas Bernard 5 * This software is subject to the conditions detailed 6 * in the LICENCE file provided within the distribution */ 7 8#ifndef __OPTIONS_H__ 9#define __OPTIONS_H__ 10 11#include "config.h" 12 13/* enum of option available in the miniupnpd.conf */ 14enum upnpconfigoptions { 15 UPNP_INVALID = 0, 16 UPNPIFNAME = 1, /* ext_ifname */ 17 UPNPLISTENING_IP, /* listening_ip */ 18 UPNPPORT, /* port */ 19 UPNPPRESENTATIONURL, /* presentation_url */ 20 UPNPNOTIFY_INTERVAL, /* notify_interval */ 21 UPNPSYSTEM_UPTIME, /* system_uptime */ 22 UPNPUUID, /* uuid */ 23 UPNPSERIAL, /* serial */ 24 UPNPMODEL_NUMBER, /* model_number */ 25 UPNPFRIENDLYNAME, /* how the system should show up to DLNA clients */ 26 UPNPMEDIADIR, /* directory to search for UPnP-A/V content */ 27 UPNPALBUMART_NAMES, /* list of '/'-delimited file names to check for album art */ 28 UPNPINOTIFY, /* enable inotify on the media directories */ 29 UPNPDBDIR, /* base directory to store the database, log files, and album art cache */ 30 ENABLE_TIVO, /* enable support for streaming images and music to TiVo */ 31 ENABLE_DLNA_STRICT /* strictly adhere to DLNA specs */ 32}; 33 34/* readoptionsfile() 35 * parse and store the option file values 36 * returns: 0 success, -1 failure */ 37int 38readoptionsfile(const char * fname); 39 40/* freeoptions() 41 * frees memory allocated to option values */ 42void 43freeoptions(void); 44 45#define MAX_OPTION_VALUE_LEN (80) 46struct option 47{ 48 enum upnpconfigoptions id; 49 char value[MAX_OPTION_VALUE_LEN]; 50}; 51 52extern struct option * ary_options; 53extern int num_options; 54 55#endif 56 57