job000286

rhummer (rhummer)
rhummer created this job , modified by Perforce maintenance
Open
Issues with GetConfig.

We are seeing various issues when either trying to use Connection.GetP4EnvironmentVar, or when P4Server attempts to call P4Server.GetConfig() when a cwd is specified when connecting to the server.

I am either seeing a NullPtr exception, or an AccessViolation exception.

The null ptr exception looks like this:
   at Perforce.P4.Connection.Connect(Options options) in c:\tmp\49030141\P4.NET\r14.2\p4api.net\p4api.net\Connection.cs:line 393

My example is pretty simple:
repo = new Perforce.P4.Repository(new Perforce.P4.Server(new Perforce.P4.ServerAddress(string.Empty)));
var options = new Perforce.P4.Options();
options.Add("ProgramName", "P4Test");
options.Add("cwd", System.Environment.CurrentDirectory);

if (repo.Connection.Connect(options))
{
    var config = repo.Connection.GetP4EnvironmentVar("P4CONFIG");
    Console.WriteLine("P4CONFIG={0}", config);
}

This is using the 64bit zip of the compiled libraries, of the latest release 2014.2. I am also seeing it from locally compiled source, but verified I am seeing it with the prebuilt libraries provided.
  • Details
  • Comments -
Status
Open
Project
perforce-software-p4api-net
Severity
A
Reported By
rhummer
Reported Date
Modified By
Perforce maintenance
Modified Date
Owned By
rhummer
Type
Bug