| From: | Dmitriy Sarafannikov <d(dot)sarafannikov(at)bk(dot)ru> | 
|---|---|
| To: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com> | 
| Cc: | Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>, Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com> | 
| Subject: | Re[2]: [HACKERS] Incorrect error message in InitializeSessionUserId | 
| Date: | 2016-03-04 06:50:50 | 
| Message-ID: | 1457074250.87737905@f30.i.mail.ru | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
>On Fri, Mar 4, 2016, 5:23 +03:00 от Michael Paquier < michael(dot)paquier(at)gmail(dot)com >:
>
>> The patch adds the support of taking the role name from the role tuple
>> instead of using the provided rolename variable, because it is possible
>> that rolename variable is NULL if the connection is from a background
>> worker.
>>
>> The patch is fine, I didn't find any problems, I marked it as ready for
>> committer.
>>
>> IMO this patch may need to backpatch supported branches as it is
>> a bug fix. Committer can decide.
>
>+1 for the backpatch. The current error message should the rolename be
>undefined in this context is misleading for users.
>-- 
>Michael
Thanks for feedback.
This patch successfully applies to the 9.5 branch.
In 9.4 and below versions InitializeSessionUserId function has other signature:
void InitializeSessionUserId(const char *rolename)
and it is impossible to pass role Oid to this function.
In this way, the patch is relevant only to the master and 9.5 branches
Regards,
Dmitriy Sarafannikov
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Michael Paquier | 2016-03-04 06:54:44 | Re: VS 2015 support in src/tools/msvc | 
| Previous Message | Haribabu Kommi | 2016-03-04 06:27:31 | Re: ExecGather() + nworkers |