mirror of
https://github.com/servalproject/serval-dna.git
synced 2024-12-19 05:07:56 +00:00
Fix some dodgy code and remove the #warning message pointing to it
This commit is contained in:
parent
84b24b9918
commit
4e29cb1eb3
5
server.c
5
server.c
@ -416,9 +416,8 @@ int processRequest(unsigned char *packet,int len,
|
||||
if (var_id&0x80) instance=packet[++pofs];
|
||||
pofs++;
|
||||
int offset=(packet[pofs]<<8)+packet[pofs+1]; pofs+=2;
|
||||
#warning Defining SID here is masking the version passed in, which other stuff still expects to be visible? Also, does it need to be SID_STRLEN*2+1 to allow for byte->hex expansion? Or has SID_STRLEN been defined to take that into account?
|
||||
char sid[SID_STRLEN+1];
|
||||
char *hlr_sid=NULL;
|
||||
char hlr_sid_s[SID_STRLEN+1];
|
||||
|
||||
pofs+=2;
|
||||
|
||||
@ -469,7 +468,7 @@ int processRequest(unsigned char *packet,int len,
|
||||
|
||||
if (packageVariableSegment(data,&dlen,h,offset,MAX_DATA_BYTES+16))
|
||||
return setReason("packageVariableSegment() failed.");
|
||||
hlr_sid = hlrSid(hlr, ofs, sid);
|
||||
hlr_sid = hlrSid(hlr, ofs, hlr_sid_s);
|
||||
|
||||
sendDone++;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user