Unicorn with delicious cookie
Nous utilisons des cookies pour améliorer votre expérience de navigation. En savoir plus
Accepter
to the top
>
>
>
Examples of errors detected by the V309…

Examples of errors detected by the V3090 diagnostic

V3090. Unsafe locking on an object.


Old NASA World Wind (C#)

V3090 Unsafe locking on an object of type 'String'. GPSTrackerPlugin.APRS.cs 256


private int APRSParse(....)
{
  int iRet=-1;
  try
  {
    lock("ExternDllAccess")
    {
      //Call the APRS DLL
      iRet=APRSParseLinePosStat(sString,
                                ref aprsPosition,
                                ref aprsStatus);
    }
  }
  catch(Exception)
  {
    iRet=-1;
  }
  return iRet;
}

Similar errors can be found in some other places:

  • V3090 Unsafe locking on an object of type 'String'. GPSTrackerPlugin.File.cs 226
  • V3090 Unsafe locking on an object of type 'String'. GPSTrackerPlugin.File.cs 244
  • V3090 Unsafe locking on an object of type 'String'. GPSTrackerPlugin.File.cs 370
  • And 12 additional diagnostic messages.

Mono

V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. corlib-net_4_x UnixRegistryApi.cs 245


public RegistryKey Ensure (....)
{
  lock (typeof (KeyHandler)){
    ....
  }
}

Similar errors can be found in some other places:

  • V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. corlib-net_4_x UnixRegistryApi.cs 261
  • V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. corlib-net_4_x UnixRegistryApi.cs 383
  • V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. corlib-net_4_x UnixRegistryApi.cs 404
  • And 8 additional diagnostic messages.

Mono

V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. System.Runtime.Remoting-net_4_x HttpRemotingHandlerFactory.cs 61


void ConfigureHttpChannel (HttpContext context)
{
  lock (GetType())
  {
    ....
  }
}

Mono

V3090 Unsafe locking on an object of type 'String'. System.Web-net_4_x ProfileBase.cs 95


const string Profiles_SettingsPropertyCollection =
               "Profiles.SettingsPropertyCollection";
....
static void InitProperties ()
{
  ....
  lock (Profiles_SettingsPropertyCollection) {
  if (_properties == null)
    _properties = properties;
  }
}

Logify Alert Clients

V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. TempDirectoryExceptionReportSender.cs 33


protected override bool SendExceptionReportCore(....) {
  ....
  lock (typeof(OfflineDirectoryExceptionReportSender)) {
  ....
}

Emby

V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. Lmhosts.cs 49


public class Lmhosts
{
  public static NbtAddress GetByName(string host)
  {
    lock (typeof(Lmhosts))
    {
      return GetByName(new Name(host, 0x20, null));
    }
  }

  internal static NbtAddress GetByName(Name name)
  {
    lock (typeof(Lmhosts))
    {
      ....
    }
  }
}

Similar errors can be found in some other places:

  • V3090 Unsafe locking on a type. All instances of a type will have the same 'Type' object. Lmhosts.cs 57

close form

Remplissez le formulaire ci‑dessous en 2 étapes simples :

Vos coordonnées :

Étape 1
Félicitations ! Voici votre code promo !

Type de licence souhaité :

Étape 2
Team license
Enterprise licence
** En cliquant sur ce bouton, vous déclarez accepter notre politique de confidentialité
close form
Demandez des tarifs
Nouvelle licence
Renouvellement de licence
--Sélectionnez la devise--
USD
EUR
* En cliquant sur ce bouton, vous déclarez accepter notre politique de confidentialité

close form
La licence PVS‑Studio gratuit pour les spécialistes Microsoft MVP
close form
Pour obtenir la licence de votre projet open source, s’il vous plait rempliez ce formulaire
* En cliquant sur ce bouton, vous déclarez accepter notre politique de confidentialité

close form
I want to join the test
* En cliquant sur ce bouton, vous déclarez accepter notre politique de confidentialité

close form
check circle
Votre message a été envoyé.

Nous vous répondrons à


Si l'e-mail n'apparaît pas dans votre boîte de réception, recherchez-le dans l'un des dossiers suivants:

  • Promotion
  • Notifications
  • Spam