)]}'
{
  "commit": "bc72d723ec6b75c53e935e819682c3e67b83e9c1",
  "tree": "5f921ed293ba8c89cbc68ed3c8e1132c836ce882",
  "parents": [
    "436e980e2ed526832de822cbf13c317a458b78e1"
  ],
  "author": {
    "name": "Masahiro Yamada",
    "email": "masahiroy@kernel.org",
    "time": "Tue Dec 01 19:34:14 2020 +0900"
  },
  "committer": {
    "name": "Masahiro Yamada",
    "email": "masahiroy@kernel.org",
    "time": "Mon Dec 21 13:57:08 2020 +0900"
  },
  "message": "modpost: rename merror() to error()\n\nThe log function names, warn(), merror(), fatal() are inconsistent.\n\nCommit 2a11665945d5 (\"kbuild: distinguish between errors and warnings\nin modpost\") intentionally chose merror() to avoid the conflict with\nthe library function error(). See man page of error(3).\n\nBut, we are already causing the conflict with warn() because it is also\na library function. See man page of warn(3). err() would be a problem\nfor the same reason.\n\nThe common technique to work around name conflicts is to use macros.\nFor example:\n\n    /* in a header */\n    #define error(fmt, ...)  __error(fmt, ##__VA_ARGS__)\n    #define warn(fmt, ...)   __warn(fmt, ##__VA_ARGS__)\n\n    /* function definition */\n    void __error(const char *fmt, ...)\n    {\n            \u003cour implementation\u003e\n    }\n\n    void __warn(const char *fmt, ...)\n    {\n            \u003cour implementation\u003e\n    }\n\nIn this way, we can implement our own warn() and error(), still we can\ninclude \u003cerror.h\u003e and \u003cerr.h\u003e with no problem.\n\nAnd, commit 93c95e526a4e (\"modpost: rework and consolidate logging\ninterface\") already did that.\n\nSince the log functions are all macros, we can use error() without\ncausing \"conflicting types\" errors.\n\nSigned-off-by: Masahiro Yamada \u003cmasahiroy@kernel.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "f882ce0d9327f857049e914196b2e03c38dea9b1",
      "old_mode": 33188,
      "old_path": "scripts/mod/modpost.c",
      "new_id": "337f6ca4bda39a97e0849a21b42e2e7fe0edcc5e",
      "new_mode": 33188,
      "new_path": "scripts/mod/modpost.c"
    },
    {
      "type": "modify",
      "old_id": "3aa052722233b59376f16b7007ed44bc59b21cc8",
      "old_mode": 33188,
      "old_path": "scripts/mod/modpost.h",
      "new_id": "f453504ad4df1f10ee42b6305f46e2c6a806c6ac",
      "new_mode": 33188,
      "new_path": "scripts/mod/modpost.h"
    }
  ]
}
