Skip to content

Commit 037526f

Browse files
keesgregkh
authored andcommitted
staging: r8192ee: avoid leaking format string
This makes sure a format string cannot leak into the work queue name nor the printk buffer. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 12df0c3 commit 037526f

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎drivers/staging/rtl8192ee/base.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ static void _rtl_init_deferred_work(struct ieee80211_hw *hw)
469469
rtl92e_easy_concurrent_retrytimer_callback, (unsigned long)hw);
470470
/* <2> work queue */
471471
rtlpriv->works.hw = hw;
472-
rtlpriv->works.rtl_wq = alloc_workqueue(rtlpriv->cfg->name, 0, 0);
472+
rtlpriv->works.rtl_wq = alloc_workqueue("%s", 0, 0, rtlpriv->cfg->name);
473473
INIT_DELAYED_WORK(&rtlpriv->works.watchdog_wq,
474474
(void *)rtl92e_watchdog_wq_callback);
475475
INIT_DELAYED_WORK(&rtlpriv->works.ips_nic_off_wq,

‎drivers/staging/rtl8192ee/btcoexist/halbtcoutsrc.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ extern u32 btc_92edbg_type[];
9494

9595

9696
#define CL_SPRINTF snprintf
97-
#define CL_PRINTF printk
97+
#define CL_PRINTF(buf) printk("%s", buf)
9898

9999
#define BTC_PRINT(dbgtype, dbgflag, printstr, ...) \
100100
do { \

0 commit comments

Comments
 (0)