Project homepage Mailing List  Warmcat.com  API Docs  Github Mirror 
{"schema":"libjg2-1", "vpath":"/git/", "avatar":"/git/avatar/", "alang":"", "gen_ut":1746418058, "reponame":"libwebsockets", "desc":"libwebsockets lightweight C networking library", "owner": { "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },"url":"https://libwebsockets.org/repo/libwebsockets", "f":3, "items": [ {"schema":"libjg2-1", "cid":"49dfcbd2c2c7d74b3cc2c044adf5885f", "commit": {"type":"commit", "time": 1453210432, "time_ofs": 480, "oid_tree": { "oid": "50293a9e54f02198bd0c259b9605eecbce0e7f97", "alias": []}, "oid":{ "oid": "2e3bf0613977ab0ae859cd7e7cceeedc3abf0c52", "alias": []}, "msg": "coverity 156861 context destroy dereference context before NULL check", "sig_commit": { "git_time": { "time": 1453210432, "offset": 480 }, "name": "Andy Green", "email": "andy.green@linaro.org", "md5": "4863edaebb4491aa6049a4d2d9c98c2c" }, "sig_author": { "git_time": { "time": 1453210174, "offset": 480 }, "name": "Andy Green", "email": "andy.green@linaro.org", "md5": "4863edaebb4491aa6049a4d2d9c98c2c" }}, "body": "coverity 156861 context destroy dereference context before NULL check\n\nContext could be NULL only if context creation failed in the first\nplace and user error path is bad... no network connectivity at that\npoint...\n\nSigned-off-by: Andy Green \u003candy.green@linaro.org\u003e" , "diff": "diff --git a/lib/context.c b/lib/context.c\nindex 02b3f1f..26aac35 100644\n--- a/lib/context.c\n+++ b/lib/context.c\n@@ -326,13 +326,14 @@ lws_context_destroy(struct lws_context *context)\n {\n \tconst struct lws_protocols *protocol \u003d NULL;\n \tstruct lws wsi;\n-\tint n, m \u003d context-\u003ecount_threads;\n+\tint n, m;\n \n \tlwsl_notice(\u0022%s\u005cn\u0022, __func__);\n \n \tif (!context)\n \t\treturn;\n \n+\tm \u003d context-\u003ecount_threads;\n \tcontext-\u003ebeing_destroyed \u003d 1;\n \n \tmemset(\u0026wsi, 0, sizeof(wsi));\n","s":{"c":1746418058,"u": 1666}} ],"g": 2789,"chitpc": 0,"ehitpc": 0,"indexed":0 , "ab": 0, "si": 0, "db":0, "di":0, "sat":0, "lfc": "0000"}