Bugs
Search the entire project
This project's trackers
This project's forums
This project's tasks
This project's releases
This project's documents
This project's news
Project
People
Skill
Advanced search
Log In
|
New Account
Home
My Page
Projects
Code Snippets
Project Openings
Npgsql .Net Data Provider for Postgresql
Summary
Activity
Forums
Tracker
Lists
Tasks
Docs
Surveys
News
SCM
Files
[#1010750] Npgsql.Command.ExecuteReader hangs when permission error returned
View Trackers
|
Bugs
|
Download .csv
|
Monitor
Date:
2010-01-08 21:11
Priority:
3
State:
Open
Submitted by:
Blayne Bayer (
bbayer
)
Assigned to:
Nobody (None)
Npgsql Version:
2.0.7
Category:
Group:
Resolution:
None
Summary:
Npgsql.Command.ExecuteReader hangs when permission error returned
Detailed description
I am calling ExecuteReader on a NpgsqlCommand object and if postgresql returns a permissions error the application hangs. No exception is thrown. I enabled logging and the final results are below:
1/8/2010 2:38:47 PM 4536 Debug String read: aclcheck_error.
1/8/2010 2:38:47 PM 4536 Debug ErrorResponse message from Server: permission denied for relation shipments.
The user that I am connecting has didn't have select permission on the table I was selecting from. Seems like an exception should have been thrown.
Followup
Message
Date: 2010-03-01 02:14
Sender:
Francisco Figueiredo jr.
Hi, Blayne!
I tested here and couldn't reproduce your problem. I could get the exception. This is the test case I run:
using System;
using System.Data;
using Npgsql;
using NpgsqlTypes;
public class c
{
public static void Main(String[] args)
{
NpgsqlEventLog.Level = LogLevel.Debug;
NpgsqlEventLog.LogName = "NpgsqlTests.LogFile";
//NpgsqlEventLog.EchoMessages = true;
NpgsqlConnection conn = new NpgsqlConnection("Server=127.0.0.1;User id=npgsql_tests;password=npgsql_tests;");
conn.Open();
NpgsqlCommand d = new NpgsqlCommand();
NpgsqlCommand command = new NpgsqlCommand("select * from no_permission", conn);
NpgsqlDataReader dr = command.ExecuteReader();
while (dr.Read())
;
conn.Close();
}
}
Attached Files:
Changes:
No Changes Have Been Made to This Item