Hi (yes, me... again),
Tiny patch attached to prevent adding attributes with a duplicate name
to a type. It seems previous versions prevented this, but must have
been allowed in a commit since the last release.
Regards
Thom Brown
Twitter: @darkixion
IRC (freenode): dark_ixion
Registered Linux user: #516935
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
diff --git a/pgadmin/dlg/dlgType.cpp b/pgadmin/dlg/dlgType.cpp
index 5f3a36c..9c8d3e3 100644
--- a/pgadmin/dlg/dlgType.cpp
+++ b/pgadmin/dlg/dlgType.cpp
@@ -523,7 +526,7 @@ void dlgType::OnMemberAdd(wxCommandEvent &ev)
type += wxT(")");
}
- if (!name.IsEmpty())
+ if (!name.IsEmpty() && lstMembers->FindItem(-1, name, false) == -1)
{
size_t pos = lstMembers->GetItemCount();
lstMembers->InsertItem(pos, name, 0);
--
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers