<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_data(self, data):
 """Add data to the currently in progress entry. Args: data (bytes):
 The data that we want to add. Returns: int: An error code """


        if self.data_size - self.data_index < len(data):
            return Error.DESTINATION_BUFFER_TOO_SMALL

        if self.in_progress is not None:
            self.in_progress.data += data

        return Error.NO_ERROR