am 0dc5fdb9: am e630e5f4: am 919853ce: Merge "Prevent SurfaceFlinger from using layer token 31." into gingerbread

* commit '0dc5fdb9b2fd3b3e2ede5e9607bc21423f357a01':
  Prevent SurfaceFlinger from using layer token 31.
This commit is contained in:
Jamie Gennis 2011-02-27 16:04:42 -08:00 committed by Android Git Automerger
commit e7809762e1

View File

@ -2470,7 +2470,7 @@ ssize_t UserClient::getTokenForSurface(const sp<ISurface>& sur) const
} }
break; break;
} }
if (++name > 31) if (++name >= SharedBufferStack::NUM_LAYERS_MAX)
name = NO_MEMORY; name = NO_MEMORY;
} while(name >= 0); } while(name >= 0);