Fix DCHECK in ErrorDelayingOutputStream.

Test: m
Bug: 131173359
Change-Id: If0a3a9b502ccf66734c47138fb1351bcaa4c6cbf
diff --git a/libelffile/stream/error_delaying_output_stream.h b/libelffile/stream/error_delaying_output_stream.h
index b37ff4e..7553de6 100644
--- a/libelffile/stream/error_delaying_output_stream.h
+++ b/libelffile/stream/error_delaying_output_stream.h
@@ -71,8 +71,9 @@
         PLOG(ERROR) << "Failed to seek in " << GetLocation() << ". Offset=" << offset
                     << " whence=" << whence << " new_offset=" << new_offset;
         output_good_ = false;
+      } else {
+        DCHECK_EQ(actual_offset, new_offset);
       }
-      DCHECK_EQ(actual_offset, new_offset);
     }
     output_offset_ = new_offset;
     return new_offset;