On 30 Apr 1998, Manoj Srivastava wrote:
> Hi,
>
> I downloaded the source rpm, and recompiled it locally with
> some changes (I run Debian). I still am having problems with
> 2.1.98. I get errors logged as:
> ______________________________________________________________________
>
> Apr 30 03:22:26 tiamat diald[732]: Could not get socket to do packet monitoring:
>Socket type not supported
> Apr 30 03:22:27 tiamat diald[732]: Can't set line discipline: Invalid argument
> Apr 30 03:22:26 tiamat diald[732]: Diald is dieing with code 1
> ______________________________________________________________________
>
Try this patch and let me know if it works ok
diff -ur diald-0.16.dist/filter.c diald-0.16.new/filter.c
--- diald-0.16.dist/filter.c Wed Jan 21 22:20:15 1998
+++ diald-0.16.new/filter.c Thu Jan 22 22:37:52 1998
@@ -19,7 +19,7 @@
fwdfd = -1;
- if ((snoopfd = socket(AF_INET, SOCK_PACKET, htons(ETH_P_ALL))) < 0) {
+ if ((snoopfd = socket(AF_PACKET, SOCK_PACKET, htons(ETH_P_ALL))) < 0) {
syslog(LOG_ERR, "Could not get socket to do packet monitoring: %m");
die(1);
}
@@ -54,7 +54,7 @@
close(fwdfd);
fwdfd = -1;
}
- if ((fwdfd = socket(AF_INET, SOCK_PACKET, htons(ETH_P_ALL))) < 0) {
+ if ((fwdfd = socket(AF_PACKET, SOCK_PACKET, htons(ETH_P_ALL))) < 0) {
syslog(LOG_ERR, "Could not get socket to do packet forwarding: %m");
die(1);
}
@@ -100,6 +100,8 @@
int len;
if ((len = recvfrom(snoopfd,packet,4096,0,&from,&from_len)) > 0) {
+
+
/* FIXME: really if the bind succeeds, then I don't need
* this check. How can I shortcut this effectly?
* perhaps two different filter_read routines?
--
Shaw Carruthers - [EMAIL PROTECTED]
London SW14 7JW UK
This is not a sig( with homage to Magritte).
-
To unsubscribe from this list: send the line "unsubscribe linux-diald" in
the body of a message to [EMAIL PROTECTED]