Skip to content

Commit

Permalink
Return -1 if socket send fail
Browse files Browse the repository at this point in the history
  • Loading branch information
fulvius31 committed Dec 19, 2022
1 parent 2bab995 commit 4e2f16b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions ipneigh30/src/main/cpp/ip_neigh.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ int JNICALL Java_it_alessangiorgi_ipneigh30_ArpNDK_ARPFromJNI(JNIEnv *env, jclas

if(do_route_dump_request(s) < 0){
__android_log_write(ANDROID_LOG_ERROR, LOGTAG, "socket send failed");
return -1;
}else
__android_log_write(ANDROID_LOG_ERROR, LOGTAG, "socket send success");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
public class ArpNDK {

private static final String TAG = "ArpNDK";
private static final String ARPNDK_FAILED = "Arp failed";
private static final String ARPNDK_FAILED = "Arp table reading failed, are you using targetSdk 32 and an Android 13 device?";

static {
System.loadLibrary("ipneigh-android");
Expand Down

0 comments on commit 4e2f16b

Please sign in to comment.