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

TIMOB-6811: Android: Media - blob.length exception: method not supported #1134

Merged
merged 1 commit into from Jan 6, 2012

Conversation

ayeung
Copy link
Contributor

@ayeung ayeung commented Jan 6, 2012

@billdawson
Copy link
Contributor

Code review and functional test accepted. Easily reproduced failcase on device, then got a real value and no error when running with this branch.

} else {
fileSize = ((TiBaseFile) data).size();
}
return (int) fileSize;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will we ever need to return a value larger than int here? This may need to be a larger type and should also likely be unsigned.

@sptramer
Copy link
Contributor

sptramer commented Jan 6, 2012

Code reviewed; please address comments.

@marshall
Copy link
Contributor

marshall commented Jan 6, 2012

Technically to support the full 64-bit long in getLength() we would need to change both the return type and other places that use it as well, which would probably be outside the scope of this issue. For practical purposes, we probably won't be dealing with Blobs / Files > 2GB in size for a while to come. Also, FWIW Java doesn't support unsigned types

@sptramer
Copy link
Contributor

sptramer commented Jan 6, 2012

OK; that makes sense. We should just be trying to avoid downcasting, but that would obviously require a lot of changes to either codebase.

Code reviewed, APPROVED.

@sptramer
Copy link
Contributor

sptramer commented Jan 6, 2012

Functional tested, Android emulator Google API Rev 8 (Froyo) w/HVGA w/Camera w/GPS w/SDCard. Passed. APPROVED.

@sptramer
Copy link
Contributor

sptramer commented Jan 6, 2012

Confirmed the image size via adb shell. Going to push the button.

sptramer pushed a commit that referenced this pull request Jan 6, 2012
TIMOB-6811: Android: Media - blob.length exception: method not supported
@sptramer sptramer merged commit ce8becc into tidev:master Jan 6, 2012
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

Successfully merging this pull request may close these issues.

None yet

4 participants