+\r
+ Length--;\r
+ BytesInTransfer++;\r
+ }\r
+ }\r
+ \r
+ return ENDPOINT_RWSTREAM_NoError;\r
+}\r
+\r
+uint8_t Endpoint_Null_Stream(uint16_t Length,\r
+ uint16_t* const BytesProcessed)\r
+{\r
+ uint8_t ErrorCode;\r
+ uint16_t BytesInTransfer = 0;\r
+ \r
+ if ((ErrorCode = Endpoint_WaitUntilReady()))\r
+ return ErrorCode;\r
+ \r
+ if (BytesProcessed != NULL)\r
+ Length -= *BytesProcessed;\r
+\r
+ while (Length)\r
+ {\r
+ if (!(Endpoint_IsReadWriteAllowed()))\r
+ {\r
+ Endpoint_ClearIN();\r
+\r
+ if (BytesProcessed != NULL)\r
+ {\r
+ *BytesProcessed += BytesInTransfer;\r
+ return ENDPOINT_RWSTREAM_IncompleteTransfer;\r
+ }\r
+\r
+ if ((ErrorCode = Endpoint_WaitUntilReady()))\r
+ return ErrorCode;\r
+ }\r
+ else\r
+ {\r
+ Endpoint_Write_Byte(0);\r
+\r