Changeset 78086 in vbox for trunk/src/VBox/HostServices/SharedOpenGL/unpacker
- Timestamp:
- Apr 10, 2019 12:48:21 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 129942
- Location:
- trunk/src/VBox/HostServices/SharedOpenGL/unpacker
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostServices/SharedOpenGL/unpacker/unpack.py
r78076 r78086 172 172 # Verify that the provided buffer length is what we expect. 173 173 packet_length = apiutil.PacketLength( params ) 174 print("\tif(!DATA_POINTER_CHECK(%d))" % packet_length); 175 print("\t{"); 176 print("\t\tcrError(\"crUnpack%s: parameters out of range\");" % func_name); 177 print("\t\treturn;"); 178 print("\t}"); 174 if packet_length > 0: 175 print("\tif(!DATA_POINTER_CHECK(%d))" % packet_length); 176 print("\t{"); 177 print("\t\tcrError(\"crUnpack%s: parameters out of range\");" % func_name); 178 print("\t\treturn;"); 179 print("\t}"); 179 180 180 181 vector_func = apiutil.VectorFunction(func_name) … … 340 341 # Verify that the provided buffer length is what we expect. 341 342 packet_length = apiutil.PacketLength( params ) 342 print("\tif(!DATA_POINTER_CHECK(%d))" % packet_length); 343 print("\t{"); 344 print("\t\tcrError(\"crUnpack%s: parameters out of range\");" % func_name); 345 print("\t\treturn;"); 346 print("\t}"); 343 if packet_length > 0: 344 print("\tif(!DATA_POINTER_CHECK(%d))" % packet_length); 345 print("\t{"); 346 print("\t\tcrError(\"crUnpack%s: parameters out of range\");" % func_name); 347 print("\t\treturn;"); 348 print("\t}"); 347 349 348 350 MakeNormalCall( return_type, func_name, params, 8 ) -
trunk/src/VBox/HostServices/SharedOpenGL/unpacker/unpack_extend.py
r69390 r78086 18 18 #define UNPACK_EXTEND_H 1 19 19 20 #ifdef __cplusplus 21 extern "C" { 22 #endif 23 20 24 """) 21 25 … … 31 35 32 36 print(""" 37 #ifdef __cplusplus 38 } 39 #endif 40 33 41 #endif 34 42 """)
Note:
See TracChangeset
for help on using the changeset viewer.