Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sven Gestegård Robertz
LabComm
Commits
fc121fcb
Commit
fc121fcb
authored
Mar 07, 2013
by
Sven Robertz
Browse files
added user action to the action enum
parent
66b14d6e
Changes
3
Hide whitespace changes
Inline
Side-by-side
lib/c/labcomm.c
View file @
fc121fcb
...
@@ -355,6 +355,9 @@ static int signature_writer(
...
@@ -355,6 +355,9 @@ static int signature_writer(
}
break
;
}
break
;
case
labcomm_writer_available
:
{
case
labcomm_writer_available
:
{
}
break
;
}
break
;
case
labcomm_writer_send_signature
:
case
labcomm_writer_user_action
:
return
-
ENOTSUP
;
//HERE BE DRAGONS: should probably be cleaned up
}
}
return
0
;
return
0
;
...
...
lib/c/labcomm.h
View file @
fc121fcb
...
@@ -124,13 +124,14 @@ void labcomm_decoder_free(
...
@@ -124,13 +124,14 @@ void labcomm_decoder_free(
*/
*/
typedef
enum
{
typedef
enum
{
labcomm_writer_alloc
,
labcomm_writer_alloc
,
// no args
labcomm_writer_free
,
labcomm_writer_free
,
// no args
labcomm_writer_start
,
labcomm_writer_start
,
// no args
labcomm_writer_continue
,
labcomm_writer_continue
,
// no args
labcomm_writer_end
,
labcomm_writer_end
,
// no args
labcomm_writer_available
,
labcomm_writer_available
,
// no args
labcomm_writer_send_signature
labcomm_writer_send_signature
,
// args = (labcomm_signature_t*, struct labcomm_encoder*)
labcomm_writer_user_action
// args = (int user_action, ... defined by the writer)
}
labcomm_writer_action_t
;
}
labcomm_writer_action_t
;
typedef
struct
labcomm_writer
{
typedef
struct
labcomm_writer
{
...
...
lib/c/labcomm_fd_reader_writer.c
View file @
fc121fcb
...
@@ -112,6 +112,9 @@ int labcomm_fd_writer(
...
@@ -112,6 +112,9 @@ int labcomm_fd_writer(
labcomm_encode_signature
(
e
,
signature
);
labcomm_encode_signature
(
e
,
signature
);
}
break
;
}
break
;
case
labcomm_writer_user_action
:
{
result
=
-
ENOTSUP
;
}
break
;
}
}
return
result
;
return
result
;
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment