File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -1367,19 +1367,19 @@ def wrapped_callback(
13671367 if not data_ptr or data_len <= 0 :
13681368 # Error: invalid input, native code will handle if seeing
13691369 # signature size being 0
1370- return 0
1370+ return - 1
13711371
13721372 # Convert C pointer to Python bytes
13731373 data = bytes (data_ptr [:data_len ])
13741374 if not data :
13751375 # Error: empty data, native code will handle it!
1376- return 0
1376+ return - 1
13771377
13781378 # Call the user's callback
13791379 signature = callback (data )
13801380 if not signature :
13811381 # Error: empty signature, native code will handle that too!
1382- return 0
1382+ return - 1
13831383
13841384 # Copy the signature back to the C buffer (since callback is
13851385 # sued in native code)
@@ -1393,7 +1393,7 @@ def wrapped_callback(
13931393 print (
13941394 error_messages ['callback_error' ].format (
13951395 str (e )), file = sys .stderr )
1396- return 0
1396+ return - 1
13971397
13981398 # Encode strings with error handling in case it's invalid UTF8
13991399 try :
Original file line number Diff line number Diff line change 3939
4040class TestC2paSdk (unittest .TestCase ):
4141 def test_sdk_version (self ):
42- self .assertIn ("0.57 .0" , sdk_version ())
42+ self .assertIn ("0.55 .0" , sdk_version ())
4343
4444
4545class TestReader (unittest .TestCase ):
You can’t perform that action at this time.
0 commit comments