Skip to content
This repository has been archived by the owner on Feb 20, 2021. It is now read-only.

Commit

Permalink
Fixed accessing disposed object error.
Browse files Browse the repository at this point in the history
  • Loading branch information
hveiras committed Sep 2, 2015
1 parent bb20851 commit ce2ab58
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/Simulator/ScenarioSimulator/SimulationProfile.cs
Expand Up @@ -14,7 +14,7 @@

namespace Microsoft.Practices.IoTJourney.ScenarioSimulator
{
public class SimulationProfile:IDisposable
public class SimulationProfile : IDisposable
{
private readonly SimulatorConfiguration _simulatorConfiguration;

Expand All @@ -33,8 +33,6 @@ public class SimulationProfile:IDisposable

_hostName = hostName;
_simulatorConfiguration = simulatorConfiguration;

_eventsSentCount.Dispose();
}

public void ProvisionDevices(bool force)
Expand All @@ -52,7 +50,7 @@ public void ProvisionDevices(bool force)
{
// Use the short form of the host or instance name to generate the device id.
var deviceId = string.Format(CultureInfo.InvariantCulture,
"{0}-{1}",
"{0}-{1}",
ConfigurationHelper.InstanceName, i);

var endpoint = ServiceBusEnvironment.CreateServiceUri("sb", _simulatorConfiguration.EventHubNamespace, string.Empty);
Expand Down

0 comments on commit ce2ab58

Please sign in to comment.