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

al_isSoundFilename returns true for even when '.ogg' is not in fname #11

Open
GoogleCodeExporter opened this issue Mar 17, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. al_isSoundFilename('lol.png')

Loading 'lol.png' isn't a problem because loadAssets checks al_isImgFilename 
first then if false checks al_isSoundFilename however if you tried to load 
'lol.bmp' (for whatever reason) it would try to decode it as audio data.

I'm sure the fix is to just change

        function al_isSoundFilename(fname)
        {
                return  fname.indexOf('.ogg') != -1 ||
                                fname.indexOf('.ogg') != -1 ||
                                fname.indexOf('.ogg') != -1 != -1;
        };

to

        function al_isSoundFilename(fname)
        {
                return  fname.indexOf('.ogg') != -1;
        };

Original issue reported on code.google.com by [email protected] on 19 Jul 2013 at 4:04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant