Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
b3c26d99
Commit
b3c26d99
authored
May 16, 2011
by
Rafaël Carré
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: fix hashing of text files with empty lines
the current status file for 1.1.9 is one of these
parent
d420d017
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
5 deletions
+8
-5
src/misc/update_crypto.c
src/misc/update_crypto.c
+8
-5
No files found.
src/misc/update_crypto.c
View file @
b3c26d99
...
@@ -730,15 +730,18 @@ uint8_t *hash_sha1_from_text( const char *psz_string,
...
@@ -730,15 +730,18 @@ uint8_t *hash_sha1_from_text( const char *psz_string,
while
(
*
psz_string
)
while
(
*
psz_string
)
{
{
size_t
i_len
=
strcspn
(
psz_string
,
"
\r\n
"
);
size_t
i_len
=
strcspn
(
psz_string
,
"
\r\n
"
);
if
(
!
i_len
)
break
;
if
(
i_len
)
{
gcry_md_write
(
hd
,
psz_string
,
i_len
);
gcry_md_write
(
hd
,
psz_string
,
i_len
);
psz_string
+=
i_len
;
}
gcry_md_putc
(
hd
,
'\r'
);
gcry_md_putc
(
hd
,
'\r'
);
gcry_md_putc
(
hd
,
'\n'
);
gcry_md_putc
(
hd
,
'\n'
);
psz_string
+=
i_len
;
if
(
*
psz_string
==
'\r'
)
while
(
*
psz_string
==
'\r'
||
*
psz_string
==
'\n'
)
psz_string
++
;
if
(
*
psz_string
==
'\n'
)
psz_string
++
;
psz_string
++
;
}
}
else
else
...
...
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