Advertisement
Guest User

Untitled

a guest
Jun 4th, 2015
596
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.41 KB | None | 0 0
  1. diff --git a/libhwcomposer/hwc.cpp b/libhwcomposer/hwc.cpp
  2. index 8ce7ea9..a0e2fae 100644
  3. --- a/libhwcomposer/hwc.cpp
  4. +++ b/libhwcomposer/hwc.cpp
  5. @@ -103,7 +103,7 @@ static void reset(hwc_context_t *ctx, int numDisplays,
  6. hwc_display_contents_1_t** displays) {
  7. ctx->isPaddingRound = false;
  8. memset(ctx->listStats, 0, sizeof(ctx->listStats));
  9. - for(int i = 0; i < HWC_NUM_DISPLAY_TYPES; i++) {
  10. + for(int i = 0; i < numDisplays; i++) {
  11. hwc_display_contents_1_t *list = displays[i];
  12. // XXX:SurfaceFlinger no longer guarantees that this
  13. // value is reset on every prepare. However, for the layer
  14. @@ -279,7 +279,7 @@ static int hwc_prepare(hwc_composer_device_1 *dev, size_t numDisplays,
  15. ctx->mRotMgr->configBegin();
  16. ctx->mNeedsRotator = false;
  17.  
  18. - for (int32_t i = numDisplays; i >= 0; i--) {
  19. + for (int32_t i = numDisplays-1; i >= 0; i--) {
  20. hwc_display_contents_1_t *list = displays[i];
  21. int dpy = getDpyforExternalDisplay(ctx, i);
  22. switch(dpy) {
  23. @@ -676,7 +676,7 @@ static int hwc_set(hwc_composer_device_1 *dev,
  24. {
  25. int ret = 0;
  26. hwc_context_t* ctx = (hwc_context_t*)(dev);
  27. - for (uint32_t i = 0; i <= numDisplays; i++) {
  28. + for (uint32_t i = 0; i < numDisplays; i++) {
  29. hwc_display_contents_1_t* list = displays[i];
  30. int dpy = getDpyforExternalDisplay(ctx, i);
  31. switch(dpy) {
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement