unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Masatake YAMATO <yamato@redhat.com>
To: 6255@debbugs.gnu.org
Subject: bug#6255: the notation of AF_LOCAL sockets in list-process
Date: Mon, 24 May 2010 15:45:36 +0900 (JST)	[thread overview]
Message-ID: <20100524.154536.959493690167583231.yamato@redhat.com> (raw)

This is a bug report with a patch. Please include the patch
if appreciated.

When `local' is given as :family keyword arugment of `make-network-process',
AF_LOCAL(also known as AF_UNIX) socket is created. This behavior is not changed
even if :host keyword arugment is given. This is O.K. But `list-process' doesn't 
work as we expected.

I'll explain the detail with example:

    (let ((port "/dev/log"))
      (make-network-process :name "syslog"
			    :host "127.0.0.1"
			    :noquery t
			    :service port
			    :family 'local
			    :type 'datagram))

Although "127.0.0.1" is specified at :host but `local' is
specified at :family, so `make-network-process' creates AF_LOCAL socket.
But M-x list-process tells

    Proc	  Status   Buffer Command
    ----	  ------   ------ -------
    syslog        open	   (none) (network datagram connection to 127.0.0.1)

This should be 


    Proc	  Status   Buffer Command
    ----	  ------   ------ -------
    syslog        open	   (none) (network datagram connection to /dev/log)


2010-05-23  Masatake YAMATO  <yamato@redhat.com>

	* process.c (Fmake_network_process): Reset `host'
	property if family is AF_LOCAL.

=== modified file 'src/process.c'
*** src/process.c	2010-05-04 04:00:10 +0000
--- src/process.c	2010-05-23 17:52:30 +0000
***************
*** 3352,3357 ****
--- 3352,3359 ----
      {
        /* Host is not used.  */
        host = Qnil;
+       contact = Fplist_put (contact, QChost, Qnil);
+       
        CHECK_STRING (service);
        bzero (&address_un, sizeof address_un);
        address_un.sun_family = AF_LOCAL;






             reply	other threads:[~2010-05-24  6:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-24  6:45 Masatake YAMATO [this message]
2010-05-24 20:47 ` bug#6255: the notation of AF_LOCAL sockets in list-process Stefan Monnier
2010-05-27 14:53 ` bug#6279: Resolve alias face in htmlfontify.el Masatake YAMATO
2010-05-27 15:30   ` Chong Yidong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100524.154536.959493690167583231.yamato@redhat.com \
    --to=yamato@redhat.com \
    --cc=6255@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).