Hi Arran, Thanks, I'll give it a whirl. Could I have done anything better there? I can probably update the SP to return something if the temporary table row count is zero, so we get something regardless, but then it's extra code to check it FR side..? Thanks again Andy -----Original Message----- From: Freeradius-Users [mailto:freeradius-users-bounces+andy.franks=sath.nhs.uk@lists.freeradius.org] On Behalf Of Arran Cudbard-Bell Sent: 14 December 2015 16:01 To: FreeRadius users mailing list Subject: Re: Reverse string concatenation for multiple attributes
On 14 Dec 2015, at 05:58, Franks Andy (IT Technical Architecture Manager) <Andy.Franks@sath.nhs.uk> wrote:
Hi, Just tried this and still no go..
rlm_sql (sql_SP_rsh-radius-lant): Reserved connection (0) (0) Executing select query: call get_active_sessions_for_switchport ('192.168.105.86', '2', 864000)
mysql_num_fields probably doesn't like a NULL result struct *sigh*. So you have a result function which returns a NULL pointer to indicated a result set with no rows, and then a function to get the number of fields in a result set, which SEGVs (instead of returning zero) if you pass it in that NULL pointer. Great API design that :/ Anyway pushed a fix. -Arran