Changeset 1576:76218233e446 in roaraudio


Ignore:
Timestamp:
04/13/09 02:17:06 (15 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

added support to get parameters

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libroarsndio/para.c

    r1571 r1576  
    5555 
    5656int    sio_setpar (struct sio_hdl * hdl, struct sio_par * par) { 
    57  if ( hdl == NULL ) 
     57 if ( hdl == NULL || par == NULL ) 
    5858  return 0; 
    5959 
     
    108108  return 0; 
    109109 
     110 memcpy(&(hdl->para), par, sizeof(struct sio_par)); 
     111 
    110112 return 1; 
    111113} 
    112114 
    113115int    sio_getpar (struct sio_hdl * hdl, struct sio_par * par) { 
    114  return 0; 
     116 if ( hdl == NULL || par == NULL ) 
     117  return 0; 
     118 
     119 memcpy(par, &(hdl->para), sizeof(struct sio_par)); 
     120 
     121 return 1; 
    115122} 
    116123 
Note: See TracChangeset for help on using the changeset viewer.