From ca265d2e5b380c9ef9ef8aee6bbe829c7d4d1104 Mon Sep 17 00:00:00 2001 From: Juergen Keil Date: Mon, 10 Dec 2001 11:46:38 +0000 Subject: PATH_MAX, NAME_MAX and CDROM_MEDIA_CHANGED defines missing on solaris CVS patchset: 1208 CVS date: 2001/12/10 11:46:38 --- src/input/input_cda.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/src/input/input_cda.c b/src/input/input_cda.c index 5df1d9d60..6937d609e 100644 --- a/src/input/input_cda.c +++ b/src/input/input_cda.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: input_cda.c,v 1.8 2001/12/10 10:51:53 f1rmb Exp $ + * $Id: input_cda.c,v 1.9 2001/12/10 11:46:38 jkeil Exp $ */ #ifdef HAVE_CONFIG_H @@ -39,6 +39,7 @@ #include #include #include +#include #include #include #include @@ -64,6 +65,13 @@ #define DEBUG_POS */ +#ifndef NAME_MAX +#define NAME_MAX 256 +#endif +#ifndef PATH_MAX +#define PATH_MAX 768 +#endif + #if defined(__sun) #define CDROM "/vol/dev/aliases/cdrom0" #else @@ -732,6 +740,7 @@ static void _cda_cbbd_grab_infos(cda_input_plugin_t *this) { * Return 1 if CD has been changed, 0 of not, -1 on error. */ static int _cda_is_cd_changed(cdainfo_t *cda) { +#ifdef CDROM_MEDIA_CHANGED int err, cd_changed=0; if(cda == NULL || cda->fd < 0) @@ -753,6 +762,13 @@ static int _cda_is_cd_changed(cdainfo_t *cda) { } return -1; +#else + /* + * At least on solaris, CDROM_MEDIA_CHANGED does not exist. Just return an + * error for now + */ + return -1; +#endif } /* -- cgit v1.2.3