diff options
author | Pepijn de Vos <pepijndevos@gmail.com> | 2022-07-02 13:29:44 +0200 |
---|---|---|
committer | Pepijn de Vos <pepijndevos@gmail.com> | 2022-07-02 13:29:44 +0200 |
commit | 0641ff47d9c437c02d77363d568b106c4ceae155 (patch) | |
tree | 0c2fb9f751004c7dcad0c7c618d3d6dd6b2cf0e3 /gowin/pack.cc | |
parent | b7992ec7724000f813ab053ac6042326f3795471 (diff) | |
parent | b4337d99fde46abe85cab8bdf98a681eefe1f3e1 (diff) | |
download | nextpnr-0641ff47d9c437c02d77363d568b106c4ceae155.tar.gz nextpnr-0641ff47d9c437c02d77363d568b106c4ceae155.tar.bz2 nextpnr-0641ff47d9c437c02d77363d568b106c4ceae155.zip |
Merge branch 'master' into shadowram
Diffstat (limited to 'gowin/pack.cc')
-rw-r--r-- | gowin/pack.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/gowin/pack.cc b/gowin/pack.cc index 0ba71705..fbd2092f 100644 --- a/gowin/pack.cc +++ b/gowin/pack.cc @@ -1033,9 +1033,11 @@ static void pack_io(Context *ctx) if (constr_bel != ci->attrs.end()) { constr_bel_name = constr_bel->second.as_string(); } - constr_bel = iob->attrs.find(id_BEL); - if (constr_bel != iob->attrs.end()) { - constr_bel_name = constr_bel->second.as_string(); + if (iob != nullptr) { + constr_bel = iob->attrs.find(id_BEL); + if (constr_bel != iob->attrs.end()) { + constr_bel_name = constr_bel->second.as_string(); + } } if (!constr_bel_name.empty()) { BelId constr_bel = ctx->getBelByNameStr(constr_bel_name); |