s/struct _serial_t/struct serial/
This commit is contained in:
parent
7081ff0445
commit
65e2f7407a
3 changed files with 16 additions and 6 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2001-07-09 Andrew Cagney <ac131313@redhat.com>
|
||||||
|
|
||||||
|
* serial.h (struct serial): Rename `struct _serial_t'.
|
||||||
|
* serial.c (XMALLOC): Define.
|
||||||
|
(serial_open): Update. Use XMALLOC.
|
||||||
|
(serial_fdopen): Ditto.
|
||||||
|
|
||||||
2001-07-07 Andrew Cagney <ac131313@redhat.com>
|
2001-07-07 Andrew Cagney <ac131313@redhat.com>
|
||||||
|
|
||||||
* gdbtypes.h (builtin_type_void_data_ptr): Rename
|
* gdbtypes.h (builtin_type_void_data_ptr): Rename
|
||||||
|
|
|
@ -58,6 +58,9 @@ static const char logbase_ascii[] = "ascii";
|
||||||
static const char *logbase_enums[] =
|
static const char *logbase_enums[] =
|
||||||
{logbase_hex, logbase_octal, logbase_ascii, NULL};
|
{logbase_hex, logbase_octal, logbase_ascii, NULL};
|
||||||
static const char *serial_logbase = logbase_ascii;
|
static const char *serial_logbase = logbase_ascii;
|
||||||
|
|
||||||
|
#undef XMALLOC
|
||||||
|
#define XMALLOC(TYPE) ((TYPE*) xmalloc (sizeof (TYPE)))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -202,7 +205,7 @@ serial_open (const char *name)
|
||||||
if (!ops)
|
if (!ops)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
scb = (serial_t) xmalloc (sizeof (struct _serial_t));
|
scb = XMALLOC (struct serial);
|
||||||
|
|
||||||
scb->ops = ops;
|
scb->ops = ops;
|
||||||
|
|
||||||
|
@ -254,7 +257,7 @@ serial_fdopen (const int fd)
|
||||||
if (!ops)
|
if (!ops)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
scb = (serial_t) xmalloc (sizeof (struct _serial_t));
|
scb = XMALLOC (struct serial);
|
||||||
|
|
||||||
scb->ops = ops;
|
scb->ops = ops;
|
||||||
|
|
||||||
|
|
|
@ -29,8 +29,8 @@
|
||||||
interface. */
|
interface. */
|
||||||
|
|
||||||
typedef void *serial_ttystate;
|
typedef void *serial_ttystate;
|
||||||
struct _serial_t;
|
struct serial;
|
||||||
typedef struct _serial_t *serial_t;
|
typedef struct serial *serial_t;
|
||||||
|
|
||||||
/* Try to open NAME. Returns a new serial_t on success, NULL on
|
/* Try to open NAME. Returns a new serial_t on success, NULL on
|
||||||
failure. */
|
failure. */
|
||||||
|
@ -199,7 +199,7 @@ extern int serial_debug_p (serial_t scb);
|
||||||
|
|
||||||
/* Details of an instance of a serial object */
|
/* Details of an instance of a serial object */
|
||||||
|
|
||||||
struct _serial_t
|
struct serial
|
||||||
{
|
{
|
||||||
int fd; /* File descriptor */
|
int fd; /* File descriptor */
|
||||||
struct serial_ops *ops; /* Function vector */
|
struct serial_ops *ops; /* Function vector */
|
||||||
|
@ -215,7 +215,7 @@ struct _serial_t
|
||||||
still need to wait for this many
|
still need to wait for this many
|
||||||
more seconds. */
|
more seconds. */
|
||||||
char *name; /* The name of the device or host */
|
char *name; /* The name of the device or host */
|
||||||
struct _serial_t *next; /* Pointer to the next serial_t */
|
struct serial *next; /* Pointer to the next serial_t */
|
||||||
int refcnt; /* Number of pointers to this block */
|
int refcnt; /* Number of pointers to this block */
|
||||||
int debug_p; /* Trace this serial devices operation. */
|
int debug_p; /* Trace this serial devices operation. */
|
||||||
int async_state; /* Async internal state. */
|
int async_state; /* Async internal state. */
|
||||||
|
|
Loading…
Reference in a new issue