Skip to content

Commit ba2ae60

Browse files
committed
wifi-scripts: ucode: fix invalid generated MAC address
macaddr_base can be NULL, in which case it needs to be passed as an empty string Signed-off-by: Felix Fietkau <nbd@nbd.name>
1 parent 165ca3f commit ba2ae60

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • package/network/config/wifi-scripts/files-ucode/usr/share/ucode/wifi

package/network/config/wifi-scripts/files-ucode/usr/share/ucode/wifi/iface.uc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ function macaddr_random() {
231231
let mac_idx = 0;
232232
export function prepare(data, phy, num_global_macaddr, macaddr_base) {
233233
if (!data.macaddr) {
234-
let pipe = fs.popen(`ucode /usr/share/hostap/wdev.uc ${phy} get_macaddr id=${mac_idx} num_global=${num_global_macaddr} mbssid=${data.mbssid ?? 0} macaddr_base=${macaddr_base}`);
234+
let pipe = fs.popen(`ucode /usr/share/hostap/wdev.uc ${phy} get_macaddr id=${mac_idx} num_global=${num_global_macaddr} mbssid=${data.mbssid ?? 0} macaddr_base=${macaddr_base ?? ""}`);
235235

236236
data.macaddr = trim(pipe.read("all"), '\n');
237237
pipe.close();

0 commit comments

Comments
 (0)