-
Notifications
You must be signed in to change notification settings - Fork 10
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
Error reading some flac files #54
Comments
Hello @pkfox sorry I didn't see your post sooner. Could you share one or more of the files that are failling? The GetUInt64 function is a generic function, so from that it's hard to say what part of the file the library is having issues with. If you can't provide the file, are you able to get the full stack trace of the exception? Thanks for the help! |
Nocturne No 1 in B flat minor Op 9 No 1.zip Hi Aaron thanks for getting back to me - having done some research I think the problem stems from the fact that, I have a lot of flac files that don't have the magic marker fLaC in the header , they were ripped a long time ago by a Linux program called Grip. As you can see the in the file I've supplied the magic marker is ID3 so it failed the VerifyFlacIdentity() in FlacFile.cs. To progress further into the program I commented out the call to VerifyFlacIdentity() and then got the error I reported. Hope that helps. |
Thanks! The problem doesn't seem to be that it doesn't have a fLaC marker. It's actually there a little further, but it looks like a big blob of ID3 metadata is put in front of it. Since |
@pkfox I think I covered that case now, if you have some time could you try it out with this branch on some of your files and let me know how it goes? |
Hi Aaron all is good now - thanks very much |
Good news! I'll make a release. Thanks a lot for taking the time to report the issue, this made the library more useful! |
The fix is in the newly published release version 3.2.1 |
Hi Aaron , thanks for the great library - I'm seeing this exception when opening certain ( not all ) flac files.
It is thrown here which is in BinaryDataHelper.cs
public static UInt64 GetUInt64(byte[] data, int byteOffset, int bitCount, byte bitOffset)
Specified argument was out of the range of valid values.
Parameter name: Provided arguments would require reading outside of the data array upper bounds
The text was updated successfully, but these errors were encountered: