OSDN Git Service

Return error code if setting scaling mode fails
authorMarco Nelissen <marcone@google.com>
Tue, 5 Feb 2013 17:03:22 +0000 (09:03 -0800)
committerMarco Nelissen <marcone@google.com>
Tue, 5 Feb 2013 17:03:22 +0000 (09:03 -0800)
The return code from native_window_set_scaling_mode() was ignored.
Looking at the code review comments that introduced this code, it
seems like the intention was to return the error code in that case.

Change-Id: I9592cc378f0a0b960d37178aa0525fc17e8734ba

media/libstagefright/AwesomePlayer.cpp

index 23ce088..0f4d866 100644 (file)
@@ -2511,6 +2511,7 @@ status_t AwesomePlayer::setVideoScalingMode_l(int32_t mode) {
         if (err != OK) {
             ALOGW("Failed to set scaling mode: %d", err);
         }
+        return err;
     }
     return OK;
 }