Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
elphel-apps-camogm
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Elphel
elphel-apps-camogm
Commits
2f60099a
Commit
2f60099a
authored
Jul 19, 2016
by
Mikhail Karpenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix a couple of compiler warnings
parent
c4ada33f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
camogm_ogm.c
camogm_ogm.c
+3
-5
No files found.
camogm_ogm.c
View file @
2f60099a
...
...
@@ -70,7 +70,7 @@ int camogm_start_ogm(camogm_state *state)
memcpy
(
&
hdbuf
[
1
],
&
sh
,
sizeof
(
sh
));
hdbuf
[
0
]
=
1
;
// put it into Ogg stream
ogg_header
.
packet
=
hdbuf
;
ogg_header
.
packet
=
(
unsigned
char
*
)
hdbuf
;
ogg_header
.
bytes
=
sizeof
(
sh
)
+
1
;
ogg_header
.
b_o_s
=
1
;
ogg_header
.
e_o_s
=
0
;
...
...
@@ -80,10 +80,9 @@ int camogm_start_ogm(camogm_state *state)
// while(ogg_stream_pageout(&(state->os), &(state->og))) {
while
(
ogg_stream_flush
(
&
(
state
->
os
),
&
(
state
->
og
)))
{
int
i
,
j
;
int
i
;
if
((((
i
=
fwrite
(
state
->
og
.
header
,
1
,
state
->
og
.
header_len
,
state
->
vf
)))
!=
state
->
og
.
header_len
)
||
(
state
->
og
.
body_len
&&
(((
i
=
fwrite
(
state
->
og
.
body
,
1
,
state
->
og
.
body_len
,
state
->
vf
)))
!=
state
->
og
.
body_len
)))
{
j
=
errno
;
D2
(
fprintf
(
debug_file
,
"
\n
%d %ld %ld
\n
"
,
i
,
state
->
og
.
header_len
,
state
->
og
.
body_len
));
return
-
CAMOGM_FRAME_FILE_ERR
;
}
...
...
@@ -194,10 +193,9 @@ int camogm_end_ogm(camogm_state *state)
ogg_header
.
granulepos
=
++
(
state
->
granulepos
);
ogg_stream_packetin
(
&
(
state
->
os
),
&
ogg_header
);
// +++++++++++++++++++++++++++++++++++++++++++++++++++++
while
(
ogg_stream_flush
(
&
(
state
->
os
),
&
(
state
->
og
)))
{
int
i
,
j
;
int
i
;
if
((((
i
=
fwrite
(
state
->
og
.
header
,
1
,
state
->
og
.
header_len
,
state
->
vf
)))
!=
state
->
og
.
header_len
)
||
(
state
->
og
.
body_len
&&
(((
i
=
fwrite
(
state
->
og
.
body
,
1
,
state
->
og
.
body_len
,
state
->
vf
)))
!=
state
->
og
.
body_len
)))
{
j
=
errno
;
D0
(
fprintf
(
debug_file
,
"
\n
%d %ld %ld
\n
"
,
i
,
state
->
og
.
header_len
,
state
->
og
.
body_len
));
return
-
CAMOGM_FRAME_FILE_ERR
;
}
...
...
Write
Preview
Markdown
is supported
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