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-25219] Android: FileNotFoundExceptions should not be inside the Titanium log #9391

Merged
merged 8 commits into from
May 19, 2018
Original file line number Diff line number Diff line change
Expand Up @@ -883,7 +883,7 @@ public Bounds peekBounds()

/**
* Based on the underlying type of reference this is, figures out how to get
* an InputStream for it. E.g., if a blob, calls blob.getInputStream, if
* an InputStream for it. E.g., if a blob, calls blob.getInputStream, if
* a resource id, calls context.getTiApp().getResources().openRawResource(resourceId).
* @return InputStream or null if problem getting it (check logcat in that case)
*/
Expand All @@ -896,14 +896,14 @@ public InputStream getInputStream()
stream = TiFileHelper.getInstance().openInputStream(url, false);

} catch (IOException e) {
Log.e(TAG, "Problem opening stream with url " + url + ": " + e.getMessage(), e);
Log.e(TAG, "Problem opening stream with url " + url + ": " + e.getMessage());
}

} else if (isTypeFile() && file != null) {
try {
stream = file.getInputStream();
} catch (IOException e) {
Log.e(TAG, "Problem opening stream from file " + file.name() + ": " + e.getMessage(), e);
Log.e(TAG, "Problem opening stream from file " + file.name() + ": " + e.getMessage());
}

} else if (isTypeBlob() && blob != null) {
Expand All @@ -924,7 +924,7 @@ public InputStream getInputStream()

/**
* Calculates a value for the BitmapFactory.Options .inSampleSize property.
*
*
* @see <a href="http://developer.android.com/reference/android/graphics/BitmapFactory.Options.html#inSampleSize">BitmapFactory.Options.inSampleSize</a>
* @param srcWidth int
* @param srcHeight int
Expand All @@ -942,7 +942,7 @@ public int calcSampleSize(int srcWidth, int srcHeight, int destWidth, int destHe

/**
* Calculates a value for the BitmapFactory.Options .inSampleSize property.
*
*
* @see <a href="http://developer.android.com/reference/android/graphics/BitmapFactory.Options.html#inSampleSize">BitmapFactory.Options.inSampleSize</a>
* @param srcWidth int
* @param srcHeight int
Expand Down