Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent line terminators #2

Closed
JovialJerboa opened this issue Aug 6, 2013 · 2 comments
Closed

Inconsistent line terminators #2

JovialJerboa opened this issue Aug 6, 2013 · 2 comments

Comments

@JovialJerboa
Copy link

Hey,

I'm having trouble cloning your repo due to the file crypto/src/asn1/isismtt/x509/AdmissionSyntax.cs. I think the problem is that the file has inconsistent line terminators and I'm running with Git's standard eol settings that convert text files to native line endings. As a result I get garbage output in the file.

For reference if I disable my eol settings (or download the repo as an zip archive) I can confirm the line ending issue. Running the UNIX tool "file" on all the files in the repo confirms that all files have the Linux LF file terminator (default Git internal representation) with the exception of AdmissionSyntax.cs:
./crypto/src/asn1/isismtt/x509/AdmissionSyntax.cs: Little-endian UTF-16 Unicode text, with CRLF, CR line terminators

I've seen this sort of thing before when tools like Visual Studio get a little bit confused about the line endings...

Would it be possible for you to fix this?

Thanks =)

@bcgit
Copy link
Collaborator

bcgit commented Aug 6, 2013

I've fixed the line endings. The file is currently been treated as binary, looking into that.

@ghost ghost assigned bcgit Aug 6, 2013
@JovialJerboa
Copy link
Author

Thanks for the quick turn around.

On the note of Git thinking the file is binary, I believe Git has a troubled history with UTF-16 encoded files. From memory I think it generally "knows" they're not binary, but cannot diff them out of the box. You can get around that by specifying a UTF-16 compliant diff tool in the .gitattributes file for the repo.

An easier solution might be to change the encoding to something git can handle a little better, for example UTF-8.

Hope that helps.

clairernovotny referenced this issue in novotnyllc/bc-csharp Dec 3, 2016
clairernovotny referenced this issue in novotnyllc/bc-csharp Dec 5, 2016
jwtvh pushed a commit to jwtvh/bc-csharp that referenced this issue Nov 27, 2017
@bcgit bcgit removed their assignment May 26, 2020
ashley-almeida pushed a commit to ashley-almeida/bc-csharp that referenced this issue Mar 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants