Commit 1d21e6a1 authored by Erik Hovland's avatar Erik Hovland

Remove all trailing whitespace,

parent 4e6d2d86
......@@ -11,7 +11,7 @@
that this copyright and permissions notice appear in all copies and
derivatives, and that no charge may be made for the software and its
documentation except to cover cost of distribution.
This software is supplied "as is" without express or implied warranty.
But that said, if there are any problems please get in touch.
......
......@@ -11,7 +11,7 @@
that this copyright and permissions notice appear in all copies and
derivatives, and that no charge may be made for the software and its
documentation except to cover cost of distribution.
*/
#ifndef DIRENT_INCLUDED
......
/*
* $Id$
* $Name$
*
*
* Adopted from Apache DSO code.
* Portions copyright Apache Software Foundation
*
......@@ -32,14 +32,14 @@ void *dlopen(const char *module_name, int mode)
p = path;
while (p = strchr(p, '/'))
*p = '\\';
/* First assume the dso/dll's required by -this- dso are sitting in the
/* First assume the dso/dll's required by -this- dso are sitting in the
* same path or can be found in the usual places. Failing that, let's
* let that dso look in the apache root.
*/
em = SetErrorMode(SEM_FAILCRITICALERRORS);
dsoh = LoadLibraryEx(path, NULL, LOAD_WITH_ALTERED_SEARCH_PATH);
if (!dsoh)
if (!dsoh)
{
SetLastError(0); // clear the last error
dsoh = LoadLibraryEx(path, NULL, 0);
......@@ -57,23 +57,23 @@ char *dlerror(void)
* mostly a potential problem for isapi modules, since LoadModule
* errors are handled within a single config thread.
*/
if((nErrorCode = GetLastError()) == 0)
return((char *)0);
SetLastError(0); // clear the last error
len = snprintf(errstr, sizeof(errstr), "(%d) ", nErrorCode);
len += FormatMessage(
len += FormatMessage(
FORMAT_MESSAGE_FROM_SYSTEM,
NULL,
nErrorCode,
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), /* Default language */
(LPTSTR) errstr + len,
sizeof(errstr) - len,
NULL
NULL
);
/* FormatMessage may have appended a newline (\r\n). So remove it
/* FormatMessage may have appended a newline (\r\n). So remove it
* and use ": " instead like the Unix errors. The error may also
* end with a . before the return - if so, trash it.
*/
......
......@@ -23,7 +23,7 @@
License along with the GNU C Library; see the file COPYING.LIB. If not,
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* This tells Alpha OSF/1 not to define a getopt prototype in <stdio.h>.
Ditto for AIX 3.2 and <stdlib.h>. */
#ifndef _NO_PROTO
......@@ -200,7 +200,7 @@ ordering;
/* Value of POSIXLY_CORRECT environment variable. */
static char *posixly_correct;
#ifdef __GNU_LIBRARY__
/* We want to avoid inclusion of string.h with non-GNU libraries
because there are many ways it can cause trouble.
......@@ -243,7 +243,7 @@ extern int strlen(const char *);
#endif /* __GNUC__ */
#endif /* not __GNU_LIBRARY__ */
/* Handle permutation of arguments. */
/* Describe the part of ARGV that contains non-options that have
......@@ -410,7 +410,7 @@ static const char *
return optstring;
}
/* Scan elements of ARGV (whose length is ARGC) for option characters
given in OPTSTRING.
......@@ -935,7 +935,7 @@ int
}
#endif /* Not ELIDE_CODE. */
#ifdef TEST
/* Compile with -DTEST to make an executable for use in testing
......
/*
/*
* Copyright (C) 2000-2001 the xine project
*
*
* This file is part of xine, a unix video player.
*
*
* xine is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* xine is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
......@@ -46,7 +46,7 @@ int gettimeofday( struct timeval *tp, struct timezone *tzp )
if( !startseconds )
startseconds = time( 0 );
timeGetSystemTime( &mmtime, sizeof( mmtime ) );
timeGetSystemTime( &mmtime, sizeof( mmtime ) );
tp->tv_sec = ( mmtime.u.ms / 1000 ) + startseconds;
tp->tv_usec = ( mmtime.u.ms % 1000 ) * 1000;
......@@ -56,7 +56,7 @@ int gettimeofday( struct timeval *tp, struct timezone *tzp )
/*
These functions are designed to mimick
a subset of itimer for use with the
a subset of itimer for use with the
alarm signal on win32. This is just
enough for xine to work.
*/
......@@ -66,7 +66,7 @@ static HANDLE sigalarm = 0;
int setitimer( int which, struct itimerval * value, struct itimerval *ovalue )
{
long int miliseconds;
if( !sigalarm )
sigalarm = CreateEvent( 0, FALSE, TRUE, "SIGALARM" );
......
......@@ -10,7 +10,7 @@
// time reference
// ----------------------------------
//
//
// 1,000 milliseconds / sec
// 1,000,000 microseconds / sec
// 1,000,000,000 nanoseconds / sec
......
......@@ -3,7 +3,7 @@
/*
* $Id$
* $Name$
*
*
*
*/
extern void *dlopen (const char *file, int mode);
......
/* !! DO NO EDIT THIS FILE, it is automatically generated */
/*
/*
* Copyright (C) 2001 Rich Wareham <richwareham@users.sourceforge.net>
*
*
* This file is part of libdvdnav, a DVD navigation library.
*
*
* libdvdnav is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* libdvdnav is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
......@@ -71,7 +71,7 @@ typedef struct read_cache_s read_cache_t;
/*
* These are defined here because they are
* not in ifo_types.h, they maybe one day
* not in ifo_types.h, they maybe one day
*/
#ifndef audio_status_t
......@@ -84,7 +84,7 @@ typedef struct {
#else
uint8_t zero2;
unsigned int stream_number : 3;
unsigned int zero1 : 4;
unsigned int zero1 : 4;
unsigned int available : 1;
#endif
} ATTRIBUTE_PACKED audio_status_t;
......@@ -121,8 +121,8 @@ typedef struct dvdnav_vobu_s {
int32_t vobu_length;
int32_t blockN; /* Relative offset */
int32_t vobu_next; /* Relative offset */
} dvdnav_vobu_t;
} dvdnav_vobu_t;
/** The main DVDNAV type **/
struct dvdnav_s {
......@@ -131,26 +131,26 @@ struct dvdnav_s {
dvd_file_t *file; /* Currently opened file */
int open_vtsN; /* The domain and number of the... */
int open_domain; /* ..currently opened VOB */
/* Position data */
vm_position_t position_next;
vm_position_t position_current;
dvdnav_vobu_t vobu;
dvdnav_vobu_t vobu;
/* NAV data */
pci_t pci;
dsi_t dsi;
uint32_t last_cmd_nav_lbn; /* detects when a command is issued on an already left NAV */
/* Flags */
int skip_still; /* Set when skipping a still */
int sync_wait; /* applications should wait till they are in sync with us */
int sync_wait_skip; /* Set when skipping wait state */
int spu_clut_changed; /* The SPU CLUT changed */
int spu_clut_changed; /* The SPU CLUT changed */
int started; /* vm_start has been called? */
int use_read_ahead; /* 1 - use read-ahead cache, 0 - don't */
int pgc_based; /* positioning works PGC based instead of PG based */
/* VM */
vm_t *vm;
pthread_mutex_t vm_lock;
......
/*
/*
* Copyright (C) 2000-2001 the xine project
*
*
* This file is part of xine, a unix video player.
*
*
* xine is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* xine is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
......
......@@ -3,8 +3,8 @@
/*
* $Id$
* $Name$
*
* win32 types
*
* win32 types
* 04 Sept 2001 - Chris Wolf create.
*/
......
/* This is the POSIX thread API (POSIX 1003).
*
*
* Pthreads-win32 - POSIX Threads Library for Win32
* Copyright (C) 1998
*
......@@ -131,7 +131,7 @@ struct timespec {
#define SIG_BLOCK 0
#endif /* SIG_BLOCK */
#ifndef SIG_UNBLOCK
#ifndef SIG_UNBLOCK
#define SIG_UNBLOCK 1
#endif /* SIG_UNBLOCK */
......@@ -492,7 +492,7 @@ enum
* C++ and C built versions will not.
*/
/*
/*
* define defaults for cleanup code
*/
#if !defined( __CLEANUP_SEH ) && !defined( __CLEANUP_CXX ) && !defined( __CLEANUP_C )
......@@ -875,7 +875,7 @@ int pthread_getschedparam (pthread_t thread,
struct sched_param *param);
int pthread_setconcurrency (int);
int pthread_getconcurrency (void);
/*
......
......@@ -3,7 +3,7 @@
*
* Purpose:
* Provides an implementation of POSIX realtime extensions
* as defined in
* as defined in
*
* POSIX 1003.1b-1993 (POSIX.1b)
*
......
/*
/*
* Copyright (C) 2000-2001 the xine project
*
*
* This file is part of xine, a unix video player.
*
*
* xine is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* xine is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
......
......@@ -10,7 +10,7 @@
// time reference
// ----------------------------------
//
//
// 1,000 milliseconds / sec
// 1,000,000 microseconds / sec
// 1,000,000,000 nanoseconds / sec
......
/*
/*
* Copyright (C) 2000-2001 the xine project
*
*
* This file is part of xine, a unix video player.
*
*
* xine is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* xine is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
......@@ -21,7 +21,7 @@
* by Matthew Grooms <elon@altavista.com>
*
* unistd.h - This is mostly a catch all header that maps standard unix
* libc calls to the equivelent win32 functions.
* libc calls to the equivelent win32 functions.
*
*/
......
......@@ -23,12 +23,12 @@
#include <config.h>
#if defined(WORDS_BIGENDIAN)
/* All bigendian systems are fine, just ignore the swaps. */
/* All bigendian systems are fine, just ignore the swaps. */
#define B2N_16(x) (void)(x)
#define B2N_32(x) (void)(x)
#define B2N_64(x) (void)(x)
#else
#else
/* For __FreeBSD_version */
#if defined(HAVE_SYS_PARAM_H)
......@@ -65,10 +65,10 @@
#define B2N_32(x) x = be32toh(x)
#define B2N_64(x) x = be64toh(x)
/* This is a slow but portable implementation, it has multiple evaluation
/* This is a slow but portable implementation, it has multiple evaluation
* problems so beware.
* Old FreeBSD's and Solaris don't have <byteswap.h> or any other such
* functionality!
* Old FreeBSD's and Solaris don't have <byteswap.h> or any other such
* functionality!
*/
#elif defined(__FreeBSD__) || defined(__sun) || defined(__bsdi__) || defined(WIN32) || defined(__CYGWIN__) || defined(__BEOS__)
......
......@@ -6,7 +6,7 @@
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
......@@ -32,7 +32,7 @@
dvd_input_t (*dvdinput_open) (const char *);
int (*dvdinput_close) (dvd_input_t);
int (*dvdinput_seek) (dvd_input_t, int);
int (*dvdinput_title) (dvd_input_t, int);
int (*dvdinput_title) (dvd_input_t, int);
int (*dvdinput_read) (dvd_input_t, void *, int, int);
char * (*dvdinput_error) (dvd_input_t);
......@@ -59,7 +59,7 @@ typedef struct dvdcss_s *dvdcss_handle;
static dvdcss_handle (*DVDcss_open) (const char *);
static int (*DVDcss_close) (dvdcss_handle);
static int (*DVDcss_seek) (dvdcss_handle, int, int);
static int (*DVDcss_title) (dvdcss_handle, int);
static int (*DVDcss_title) (dvdcss_handle, int);
static int (*DVDcss_read) (dvdcss_handle, void *, int, int);
static char * (*DVDcss_error) (dvdcss_handle);
#endif
......@@ -68,7 +68,7 @@ static char * (*DVDcss_error) (dvdcss_handle);
struct dvd_input_s {
/* libdvdcss handle */
dvdcss_handle dvdcss;
/* dummy file input */
int fd;
};
......@@ -80,14 +80,14 @@ struct dvd_input_s {
static dvd_input_t css_open(const char *target)
{
dvd_input_t dev;
/* Allocate the handle structure */
dev = (dvd_input_t) malloc(sizeof(*dev));
if(dev == NULL) {
fprintf(stderr, "libdvdread: Could not allocate memory.\n");
return NULL;
}
/* Really open it with libdvdcss */
dev->dvdcss = DVDcss_open(target);
if(dev->dvdcss == 0) {
......@@ -95,7 +95,7 @@ static dvd_input_t css_open(const char *target)
free(dev);
return NULL;
}
return dev;
}
......@@ -155,14 +155,14 @@ static int css_close(dvd_input_t dev)
static dvd_input_t file_open(const char *target)
{
dvd_input_t dev;
/* Allocate the library structure */
dev = (dvd_input_t) malloc(sizeof(*dev));
if(dev == NULL) {
fprintf(stderr, "libdvdread: Could not allocate memory.\n");
return NULL;
}
/* Open the device */
#ifndef WIN32
dev->fd = open(target, O_RDONLY);
......@@ -174,7 +174,7 @@ static dvd_input_t file_open(const char *target)
free(dev);
return NULL;
}
return dev;
}
......@@ -217,20 +217,20 @@ static int file_read(dvd_input_t dev, void *buffer, int blocks, int flags)
{
size_t len;
ssize_t ret;
len = (size_t)blocks * DVD_VIDEO_LB_LEN;
while(len > 0) {
ret = read(dev->fd, buffer, len);
if(ret < 0) {
/* One of the reads failed, too bad. We won't even bother
* returning the reads that went OK, and as in the POSIX spec
* the file position is left unspecified after a failure. */
return ret;
}
if(ret == 0) {
/* Nothing more to read. Return all of the whole blocks, if any.
* Adjust the file position back to the previous block boundary. */
......@@ -240,7 +240,7 @@ static int file_read(dvd_input_t dev, void *buffer, int blocks, int flags)
/* should have pos % 2048 == 0 */
return (int) (bytes / DVD_VIDEO_LB_LEN);
}
len -= ret;
}
......@@ -309,11 +309,11 @@ int dvdinput_setup(void)
dlsym(dvdcss_library, U_S "dvdcss_read");
DVDcss_error = (char* (*)(dvdcss_handle))
dlsym(dvdcss_library, U_S "dvdcss_error");
dvdcss_version = (char **)dlsym(dvdcss_library, U_S "dvdcss_interface_2");
if(dlsym(dvdcss_library, U_S "dvdcss_crack")) {
fprintf(stderr,
fprintf(stderr,
"libdvdread: Old (pre-0.0.2) version of libdvdcss found.\n"
"libdvdread: You should get the latest version from "
"http://www.videolan.org/\n" );
......@@ -327,7 +327,7 @@ int dvdinput_setup(void)
}
}
#endif /* HAVE_DVDCSS_DVDCSS_H */
if(dvdcss_library != NULL) {
/*
char *psz_method = getenv( "DVDCSS_METHOD" );
......@@ -337,7 +337,7 @@ int dvdinput_setup(void)
*/
fprintf(stderr, "libdvdread: Using libdvdcss version %s for DVD access\n",
dvdcss_version ? *dvdcss_version : "");
/* libdvdcss wrapper functions */
dvdinput_open = css_open;
dvdinput_close = css_close;
......@@ -346,7 +346,7 @@ int dvdinput_setup(void)
dvdinput_read = css_read;
dvdinput_error = css_error;
return 1;
} else {
fprintf(stderr, "libdvdread: Encrypted DVD support unavailable.\n");
......
......@@ -9,7 +9,7 @@
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
......@@ -36,7 +36,7 @@ typedef struct dvd_input_s *dvd_input_t;
extern dvd_input_t (*dvdinput_open) (const char *);
extern int (*dvdinput_close) (dvd_input_t);
extern int (*dvdinput_seek) (dvd_input_t, int);
extern int (*dvdinput_title) (dvd_input_t, int);
extern int (*dvdinput_title) (dvd_input_t, int);
extern int (*dvdinput_read) (dvd_input_t, void *, int, int);
extern char * (*dvdinput_error) (dvd_input_t);
......
......@@ -50,7 +50,7 @@ static inline int _private_gettimeofday( struct timeval *tv, void *tz )
#include <io.h> /* read() */
#define lseek64 _lseeki64
#endif
#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__bsdi__)|| defined(__DARWIN__)
#define SYS_BSD 1
#endif
......@@ -73,8 +73,8 @@ static inline int _private_gettimeofday( struct timeval *tv, void *tz )
struct dvd_reader_s {
/* Basic information. */
int isImageFile;
/* Hack for keeping track of the css status.
/* Hack for keeping track of the css status.
* 0: no css, 1: perhaps (need init of keys), 2: have done init */
int css_state;
int css_title; /* Last title that we have called dvdinpute_title for. */
......@@ -84,7 +84,7 @@ struct dvd_reader_s {
/* Information required for a directory path drive. */
char *path_root;
/* Filesystem cache */
int udfcache_level; /* 0 - turned off, 1 - on */
void *udfcache;
......@@ -95,7 +95,7 @@ struct dvd_reader_s {
struct dvd_file_s {
/* Basic information. */
dvd_reader_t *dvd;
/* Hack for selecting the right css title. */
int css_title;
......@@ -112,7 +112,7 @@ struct dvd_file_s {
};
int UDFReadBlocksRaw( dvd_reader_t *device, uint32_t lb_number,
size_t block_count, unsigned char *data,
size_t block_count, unsigned char *data,
int encrypted );
/**
......@@ -123,7 +123,7 @@ int UDFReadBlocksRaw( dvd_reader_t *device, uint32_t lb_number,
int DVDUDFCacheLevel(dvd_reader_t *device, int level)
{
struct dvd_reader_s *dev = (struct dvd_reader_s *)device;
if(level > 0) {
level = 1;
} else if(level < 0) {
......@@ -131,14 +131,14 @@ int DVDUDFCacheLevel(dvd_reader_t *device, int level)
}
dev->udfcache_level = level;
return level;
}
void *GetUDFCacheHandle(dvd_reader_t *device)
{
struct dvd_reader_s *dev = (struct dvd_reader_s *)device;
return dev->udfcache;
}
......@@ -159,18 +159,18 @@ static int initAllCSSKeys( dvd_reader_t *dvd )
char filename[ MAX_UDF_FILE_NAME_LEN ];
uint32_t start, len;
int title;
char *nokeys_str = getenv("DVDREAD_NOKEYS");
if(nokeys_str != NULL)
return 0;
fprintf( stderr, "\n" );
fprintf( stderr, "libdvdread: Attempting to retrieve all CSS keys\n" );
fprintf( stderr, "libdvdread: This can take a _long_ time, "
"please be patient\n\n" );
gettimeofday(&all_s, NULL);
for( title = 0; title < 100; title++ ) {
gettimeofday( &t_s, NULL );
if( title == 0 ) {
......@@ -181,40 +181,40 @@ static int initAllCSSKeys( dvd_reader_t *dvd )
start = UDFFindFile( dvd, filename, &len );
if( start != 0 && len != 0 ) {
/* Perform CSS key cracking for this title. */
fprintf( stderr, "libdvdread: Get key for %s at 0x%08x\n",
fprintf( stderr, "libdvdread: Get key for %s at 0x%08x\n",
filename, start );
if( dvdinput_title( dvd->dev, (int)start ) < 0 ) {
fprintf( stderr, "libdvdread: Error cracking CSS key for %s (0x%08x)\n", filename, start);
}
gettimeofday( &t_e, NULL );
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
(long int) t_e.tv_sec - t_s.tv_sec );
}
if( title == 0 ) continue;
gettimeofday( &t_s, NULL );
sprintf( filename, "/VIDEO_TS/VTS_%02d_%d.VOB", title, 1 );
start = UDFFindFile( dvd, filename, &len );
if( start == 0 || len == 0 ) break;
/* Perform CSS key cracking for this title. */
fprintf( stderr, "libdvdread: Get key for %s at 0x%08x\n",
fprintf( stderr, "libdvdread: Get key for %s at 0x%08x\n",
filename, start );
if( dvdinput_title( dvd->dev, (int)start ) < 0 ) {
fprintf( stderr, "libdvdread: Error cracking CSS key for %s (0x%08x)!!\n", filename, start);
}
gettimeofday( &t_e, NULL );
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
(long int) t_e.tv_sec - t_s.tv_sec );
}
title--;
fprintf( stderr, "libdvdread: Found %d VTS's\n", title );
gettimeofday(&all_e, NULL);
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
fprintf( stderr, "libdvdread: Elapsed time %ld\n",
(long int) all_e.tv_sec - all_s.tv_sec );
return 0;
}
......@@ -227,7 +227,7 @@ static dvd_reader_t *DVDOpenImageFile( const char *location, int have_css )
{
dvd_reader_t *dvd;
dvd_input_t dev;