Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8d33b7db authored by Nicholas Troast's avatar Nicholas Troast Committed by Harry Yang
Browse files

qcom-charger: smb-lib: fix return of an uninitialized variable



rc could be returned without being initialized. Initialize it.

Signed-off-by: default avatarNicholas Troast <ntroast@codeaurora.org>
Change-Id: I044f74c7853e6853ae41734a95a4d86569c60457
parent 8995a700
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2010,7 +2010,7 @@ int smblib_set_prop_pd_current_max(struct smb_charger *chg,
int smblib_set_prop_usb_current_max(struct smb_charger *chg,
				    const union power_supply_propval *val)
{
	int rc;
	int rc = 0;

	if (!chg->pd_active) {
		rc = vote(chg->usb_icl_votable, USB_PSY_VOTER,