diff
- if (build_lbl_len <= QCA_FW_BUILD_VER_LEN - 1) {
-   memcpy(build_label, edl->data + 1, build_lbl_len);
+ if (build_lbl_len > 0 && build_lbl_len <= QCA_FW_BUILD_VER_LEN - 1) {
+   snprintf(build_label, QCA_FW_BUILD_VER_LEN, "%.*s", build_lbl_len, (char *)(edl->data + 1));
