Re: Allow format 0000-0000-0000 in postgresql MAC parser

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: Herwin Weststrate <herwin(at)quarantainenet(dot)nl>
Cc: PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Allow format 0000-0000-0000 in postgresql MAC parser
Date: 2014-09-30 23:19:04
Message-ID: CAB7nPqRbDZHy9CpN_mepSt1gP9gW66R-j7tvR6Bvx6bRvZpvXA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sep 29, 2014 at 6:30 PM, Herwin Weststrate
<herwin(at)quarantainenet(dot)nl> wrote:
> Some devices send the MAC address in RADIUS requests in the format
> 0000-0000-0000. I've seen this with a 3com switch, but there may be
> others. Currently, postgresql doesn't understand this format.
>
> This patch adds an extra line to the macaddr parsing in postgres to
> support this format as well. A unit test has been added.
You should register this patch in the next commit fest where it will
be fully reviewed and hopefully committed for 9.5:
https://commitfest.postgresql.org/action/commitfest_view?id=24

Looking at your patch, you should update the documentation as well,
the list of authorized outputs being clearly listed:
http://www.postgresql.org/docs/devel/static/datatype-net-types.html#DATATYPE-MACADDR
This consists in adding simply one line to doc/src/sgml/datatype.sgml.
Regards,
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2014-09-30 23:28:22 Re: INSERT ... ON CONFLICT {UPDATE | IGNORE}
Previous Message Andres Freund 2014-09-30 23:16:52 Re: CREATE IF NOT EXISTS INDEX