Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
f2422b58
Commit
f2422b58
authored
Apr 07, 2016
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testprogs: Mark some tables as static const
parent
5b1409c7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
17 additions
and
17 deletions
+17
-17
aes-test.c
libavutil/aes-test.c
+4
-4
avstring-test.c
libavutil/avstring-test.c
+1
-1
crc-test.c
libavutil/crc-test.c
+1
-1
hmac-test.c
libavutil/hmac-test.c
+8
-8
opt-test.c
libavutil/opt-test.c
+1
-1
sha-test.c
libavutil/sha-test.c
+1
-1
xtea-test.c
libavutil/xtea-test.c
+1
-1
No files found.
libavutil/aes-test.c
View file @
f2422b58
...
@@ -27,23 +27,23 @@ int main(int argc, char **argv)
...
@@ -27,23 +27,23 @@ int main(int argc, char **argv)
{
{
int
i
,
j
;
int
i
,
j
;
AVAES
b
;
AVAES
b
;
uint8_t
rkey
[
2
][
16
]
=
{
static
const
uint8_t
rkey
[
2
][
16
]
=
{
{
0
},
{
0
},
{
0x10
,
0xa5
,
0x88
,
0x69
,
0xd7
,
0x4b
,
0xe5
,
0xa3
,
{
0x10
,
0xa5
,
0x88
,
0x69
,
0xd7
,
0x4b
,
0xe5
,
0xa3
,
0x74
,
0xcf
,
0x86
,
0x7c
,
0xfb
,
0x47
,
0x38
,
0x59
}
0x74
,
0xcf
,
0x86
,
0x7c
,
0xfb
,
0x47
,
0x38
,
0x59
}
};
};
uint8_t
pt
[
16
],
rpt
[
2
][
16
]
=
{
static
const
uint8_t
rpt
[
2
][
16
]
=
{
{
0x6a
,
0x84
,
0x86
,
0x7c
,
0xd7
,
0x7e
,
0x12
,
0xad
,
{
0x6a
,
0x84
,
0x86
,
0x7c
,
0xd7
,
0x7e
,
0x12
,
0xad
,
0x07
,
0xea
,
0x1b
,
0xe8
,
0x95
,
0xc5
,
0x3f
,
0xa3
},
0x07
,
0xea
,
0x1b
,
0xe8
,
0x95
,
0xc5
,
0x3f
,
0xa3
},
{
0
}
{
0
}
};
};
uint8_t
rct
[
2
][
16
]
=
{
static
const
uint8_t
rct
[
2
][
16
]
=
{
{
0x73
,
0x22
,
0x81
,
0xc0
,
0xa0
,
0xaa
,
0xb8
,
0xf7
,
{
0x73
,
0x22
,
0x81
,
0xc0
,
0xa0
,
0xaa
,
0xb8
,
0xf7
,
0xa5
,
0x4a
,
0x0c
,
0x67
,
0xa0
,
0xc4
,
0x5e
,
0xcf
},
0xa5
,
0x4a
,
0x0c
,
0x67
,
0xa0
,
0xc4
,
0x5e
,
0xcf
},
{
0x6d
,
0x25
,
0x1e
,
0x69
,
0x44
,
0xb0
,
0x51
,
0xe0
,
{
0x6d
,
0x25
,
0x1e
,
0x69
,
0x44
,
0xb0
,
0x51
,
0xe0
,
0x4e
,
0xaa
,
0x6f
,
0xb4
,
0xdb
,
0xf7
,
0x84
,
0x65
}
0x4e
,
0xaa
,
0x6f
,
0xb4
,
0xdb
,
0xf7
,
0x84
,
0x65
}
};
};
uint8_t
temp
[
16
];
uint8_t
pt
[
16
],
temp
[
16
];
int
err
=
0
;
int
err
=
0
;
av_log_set_level
(
AV_LOG_DEBUG
);
av_log_set_level
(
AV_LOG_DEBUG
);
...
...
libavutil/avstring-test.c
View file @
f2422b58
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
int
main
(
void
)
int
main
(
void
)
{
{
int
i
;
int
i
;
const
char
*
strings
[]
=
{
static
const
char
*
strings
[]
=
{
"''"
,
"''"
,
""
,
""
,
":"
,
":"
,
...
...
libavutil/crc-test.c
View file @
f2422b58
...
@@ -25,7 +25,7 @@ int main(void)
...
@@ -25,7 +25,7 @@ int main(void)
{
{
uint8_t
buf
[
1999
];
uint8_t
buf
[
1999
];
int
i
;
int
i
;
int
p
[
5
][
3
]
=
{
static
const
int
p
[
5
][
3
]
=
{
{
AV_CRC_32_IEEE_LE
,
0xEDB88320
,
0x3D5CDD04
},
{
AV_CRC_32_IEEE_LE
,
0xEDB88320
,
0x3D5CDD04
},
{
AV_CRC_32_IEEE
,
0x04C11DB7
,
0xC0F5BAE0
},
{
AV_CRC_32_IEEE
,
0x04C11DB7
,
0xC0F5BAE0
},
{
AV_CRC_16_ANSI_LE
,
0xA001
,
0xBFD8
},
{
AV_CRC_16_ANSI_LE
,
0xA001
,
0xBFD8
},
...
...
libavutil/hmac-test.c
View file @
f2422b58
...
@@ -42,12 +42,12 @@ int main(void)
...
@@ -42,12 +42,12 @@ int main(void)
{
{
uint8_t
key1
[
20
],
key3
[
131
],
data3
[
50
];
uint8_t
key1
[
20
],
key3
[
131
],
data3
[
50
];
enum
AVHMACType
i
=
AV_HMAC_SHA224
;
enum
AVHMACType
i
=
AV_HMAC_SHA224
;
const
uint8_t
key2
[]
=
"Jefe"
;
static
const
uint8_t
key2
[]
=
"Jefe"
;
const
uint8_t
data1
[]
=
"Hi There"
;
static
const
uint8_t
data1
[]
=
"Hi There"
;
const
uint8_t
data2
[]
=
"what do ya want for nothing?"
;
static
const
uint8_t
data2
[]
=
"what do ya want for nothing?"
;
const
uint8_t
data4
[]
=
"Test Using Larger Than Block-Size Key - Hash Key First"
;
static
const
uint8_t
data4
[]
=
"Test Using Larger Than Block-Size Key - Hash Key First"
;
const
uint8_t
data5
[]
=
"Test Using Larger Than Block-Size Key and Larger Than One Block-Size Data"
;
static
const
uint8_t
data5
[]
=
"Test Using Larger Than Block-Size Key and Larger Than One Block-Size Data"
;
const
uint8_t
data6
[]
=
"This is a test using a larger than block-size key and a larger "
static
const
uint8_t
data6
[]
=
"This is a test using a larger than block-size key and a larger "
"than block-size data. The key needs to be hashed before being used"
"than block-size data. The key needs to be hashed before being used"
" by the HMAC algorithm."
;
" by the HMAC algorithm."
;
AVHMAC
*
hmac
=
av_hmac_alloc
(
AV_HMAC_MD5
);
AVHMAC
*
hmac
=
av_hmac_alloc
(
AV_HMAC_MD5
);
...
...
libavutil/opt-test.c
View file @
f2422b58
...
@@ -68,7 +68,7 @@ int main(void)
...
@@ -68,7 +68,7 @@ int main(void)
{
{
int
i
;
int
i
;
TestContext
test_ctx
=
{
.
class
=
&
test_class
};
TestContext
test_ctx
=
{
.
class
=
&
test_class
};
const
char
*
options
[]
=
{
static
const
char
*
options
[]
=
{
""
,
""
,
":"
,
":"
,
"="
,
"="
,
...
...
libavutil/sha-test.c
View file @
f2422b58
...
@@ -25,7 +25,7 @@ int main(void)
...
@@ -25,7 +25,7 @@ int main(void)
int
i
,
j
,
k
;
int
i
,
j
,
k
;
AVSHA
ctx
;
AVSHA
ctx
;
unsigned
char
digest
[
32
];
unsigned
char
digest
[
32
];
const
int
lengths
[
3
]
=
{
160
,
224
,
256
};
static
const
int
lengths
[
3
]
=
{
160
,
224
,
256
};
for
(
j
=
0
;
j
<
3
;
j
++
)
{
for
(
j
=
0
;
j
<
3
;
j
++
)
{
printf
(
"Testing SHA-%d
\n
"
,
lengths
[
j
]);
printf
(
"Testing SHA-%d
\n
"
,
lengths
[
j
]);
...
...
libavutil/xtea-test.c
View file @
f2422b58
...
@@ -83,7 +83,7 @@ int main(void)
...
@@ -83,7 +83,7 @@ int main(void)
AVXTEA
ctx
;
AVXTEA
ctx
;
uint8_t
buf
[
16
],
iv
[
8
];
uint8_t
buf
[
16
],
iv
[
8
];
int
i
,
j
;
int
i
,
j
;
const
uint8_t
src
[
32
]
=
"HelloWorldHelloWorldHelloWorld"
;
static
const
uint8_t
src
[
32
]
=
"HelloWorldHelloWorldHelloWorld"
;
uint8_t
ct
[
32
];
uint8_t
ct
[
32
];
uint8_t
pl
[
32
];
uint8_t
pl
[
32
];
...
...
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