|
|
@ -251,6 +251,11 @@ void LP_broadcast_message(int32_t pubsock,char *base,char *rel,bits256 destpub25 |
|
|
|
if ( (methodstr= jstr(argjson,"method")) != 0 && strlen(methodstr) <= sizeof(method) ) |
|
|
|
{ |
|
|
|
strcpy(method,methodstr); |
|
|
|
jdelete(argjson,"method"); |
|
|
|
jaddstr(argjson,"method",method); |
|
|
|
msg = (void *)jprint(argjson,0); |
|
|
|
msglen = (int32_t)strlen((char *)msg) + 1; |
|
|
|
crc32 = calc_crc32(0,&msg[2],msglen - 2); |
|
|
|
if ( IAMLP == 0 ) |
|
|
|
{ |
|
|
|
jdelete(argjson,"method"); |
|
|
@ -259,9 +264,6 @@ void LP_broadcast_message(int32_t pubsock,char *base,char *rel,bits256 destpub25 |
|
|
|
jaddstr(argjson,"method2",method); |
|
|
|
jaddstr(argjson,"method","broadcast"); |
|
|
|
} |
|
|
|
msg = (void *)jprint(argjson,0); |
|
|
|
msglen = (int32_t)strlen((char *)msg) + 1; |
|
|
|
crc32 = calc_crc32(0,&msg[2],msglen - 2); |
|
|
|
//printf("CRC32.%u (%s)\n",crc32,(char *)msg);
|
|
|
|
//jdelete(argjson,"method");
|
|
|
|
//jaddstr(argjson,"method","broadcast");
|
|
|
|