mirror of
https://github.com/nmap/nmap.git
synced 2026-02-08 14:36:33 +00:00
removed unused ServiceProbe::setName and some TCPIP_DEBUGGING stuff
This commit is contained in:
@@ -851,11 +851,6 @@ ServiceProbe::~ServiceProbe() {
|
||||
if (fallbackStr) free(fallbackStr);
|
||||
}
|
||||
|
||||
void ServiceProbe::setName(const char *name) {
|
||||
if (probename) free(probename);
|
||||
probename = strdup(name);
|
||||
}
|
||||
|
||||
// Parses the "probe " line in the nmap-service-probes file. Pass the rest of the line
|
||||
// after "probe ". The format better be:
|
||||
// [TCP|UDP] [probename] q|probetext|
|
||||
|
||||
@@ -218,7 +218,6 @@ class ServiceProbe {
|
||||
ServiceProbe();
|
||||
~ServiceProbe();
|
||||
const char *getName() { return probename; }
|
||||
void setName(const char *name); // a copy of name will be made and stored
|
||||
// Returns true if this is the "null" probe, meaning it sends no probe and
|
||||
// only listens for a banner. Only TCP services have this.
|
||||
bool isNullProbe() { return (probestringlen == 0); }
|
||||
|
||||
15
tcpip.cc
15
tcpip.cc
@@ -952,11 +952,6 @@ ip->ip_dst.s_addr= victim->s_addr;
|
||||
ip->ip_sum = in_cksum((unsigned short *)ip, sizeof(struct ip));
|
||||
#endif
|
||||
|
||||
if (TCPIP_DEBUGGING > 1) {
|
||||
log_write(LOG_STDOUT, "Raw TCP packet creation completed! Here it is:\n");
|
||||
readtcppacket(packet,ntohs(ip->ip_len));
|
||||
}
|
||||
|
||||
*packetlen = ntohs(ip->ip_len);
|
||||
return packet;
|
||||
|
||||
@@ -1398,11 +1393,6 @@ u8 *build_udp_raw(struct in_addr *source, const struct in_addr *victim,
|
||||
ip->ip_sum = in_cksum((unsigned short *)ip, sizeof(struct ip));
|
||||
#endif
|
||||
|
||||
if (TCPIP_DEBUGGING > 1) {
|
||||
printf("Raw UDP packet creation completed! Here it is:\n");
|
||||
readudppacket(packet,1);
|
||||
}
|
||||
|
||||
*packetlen = ntohs(ip->ip_len);
|
||||
return packet;
|
||||
}
|
||||
@@ -1476,11 +1466,6 @@ ip->ip_sum = in_cksum((unsigned short *)ip, sizeof(struct ip));
|
||||
if (data)
|
||||
memcpy(packet + sizeof(struct ip), data, datalen);
|
||||
|
||||
if (TCPIP_DEBUGGING > 1) {
|
||||
printf("Raw IP packet creation completed! Here it is:\n");
|
||||
hdump(packet, ntohs(ip->ip_len));
|
||||
}
|
||||
|
||||
*packetlen = ntohs(ip->ip_len);
|
||||
return packet;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user