when using the = operator with media_format, check the area with B_BAD_VALUE.

Previously metadata weren't copied over the new format.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32596 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2009-08-22 09:42:38 +00:00
parent f1a7a3752f
commit e0818886cf

View File

@ -856,7 +856,7 @@ media_format::operator=(const media_format& clone)
// clone or copy the meta data
if (clone.meta_data) {
if (clone.meta_data_area) {
if (clone.meta_data_area != B_BAD_VALUE) {
meta_data_area = clone_area("meta_data_clone_area", &meta_data,
B_ANY_ADDRESS, B_READ_AREA, clone.meta_data_area);
if (meta_data_area < 0) {