/
Thread Unsafe Function Usage: dbus-glib

Thread Unsafe Function Usage: dbus-glib

This checks dbus-glib: thread unsafe functions.

But function list can be modified. (we will add more and more) => this checker should be a general purpose.

thus, checker config can be like below:

 

{
  "code""CHECK_THREAD_UNSAFE_FUNCTION_DBUS_GLIB",
  "name""Checking thread unsafe function: dbus-glib",
  "type""BOTH",
  "categoryName""Tizen",
  "severityCode""CRI",
  "version""2.5.32",
  "description""${methodName}: dbus-glib is thread unsafe function. so we recommends NOT to use dbus-glib in the multi-thread environment",
  "isActive"true,
  "properties": {
    "method-list""dbus_g_proxy_call, dbus_g_proxy_new_for_name, dbus_g_proxy_new_for_owner"
  },
  "cwe"0
}

 

  • ${methodName} : it should be replaced by a real method name that you found in a source file.
  • "method-list" : it should have value that divided by ','(comma). for example, "methodName1,methodName2,methodName3"
    you have to check method name that divided by comma.
    • so far, we have three method name : 
      dbus_g_proxy_call, dbus_g_proxy_new_for_name, dbus_g_proxy_new_for_owner
    • you can get this value by calling : String value = Your_Checker.getProperty("method-list"); 

Related content