simplify code for unused features
This commit is contained in:
parent
eee4890f2f
commit
9601818842
|
@ -24,34 +24,21 @@
|
||||||
#include <sigrok.h>
|
#include <sigrok.h>
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
static int init(struct output *o)
|
|
||||||
{
|
|
||||||
/* Prevent compiler warnings. */
|
|
||||||
o = o;
|
|
||||||
|
|
||||||
/* Nothing so far, but we might want to add stuff here later. */
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int event(struct output *o, int event_type, char **data_out,
|
static int event(struct output *o, int event_type, char **data_out,
|
||||||
uint64_t *length_out)
|
uint64_t *length_out)
|
||||||
{
|
{
|
||||||
char *outbuf;
|
|
||||||
int outlen = 1; /* FIXME */
|
|
||||||
|
|
||||||
/* Prevent compiler warnings. */
|
/* Prevent compiler warnings. */
|
||||||
o = o;
|
o = o;
|
||||||
event_type = event_type;
|
event_type = event_type;
|
||||||
|
data_out = data_out;
|
||||||
|
|
||||||
switch (event_type) {
|
switch (event_type) {
|
||||||
case DF_TRIGGER:
|
case DF_TRIGGER:
|
||||||
break;
|
break;
|
||||||
case DF_END:
|
case DF_END:
|
||||||
outbuf = calloc(1, outlen); /* FIXME */
|
*length_out = 0;
|
||||||
if (outbuf == NULL)
|
|
||||||
return SIGROK_ERR_MALLOC;
|
|
||||||
*data_out = outbuf;
|
|
||||||
*length_out = outlen;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -84,7 +71,7 @@ static int data(struct output *o, char *data_in, uint64_t length_in,
|
||||||
struct output_format output_binary = {
|
struct output_format output_binary = {
|
||||||
"binary",
|
"binary",
|
||||||
"Raw binary",
|
"Raw binary",
|
||||||
init,
|
NULL,
|
||||||
data,
|
data,
|
||||||
event,
|
event,
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue