aboutsummaryrefslogtreecommitdiff
path: root/ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c
diff options
context:
space:
mode:
Diffstat (limited to 'ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c')
-rw-r--r--ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c b/ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c
new file mode 100644
index 000000000000..0824a2afbb31
--- /dev/null
+++ b/ports-mgmt/portmanager/files/patch-libMG__src__MGdbAdd.c
@@ -0,0 +1,30 @@
+--- ./libMG/src/MGdbAdd.c.orig Mon Dec 12 15:32:34 2005
++++ ./libMG/src/MGdbAdd.c Fri Dec 8 17:13:00 2006
+@@ -39,7 +39,9 @@
+ int idx = 0;
+ va_list paramList;
+
+- /* check if we have a valid object */
++ /*
++ * check if we have a valid object
++ */
+ if( db->parent.type != CLASS_TYPE_DB )
+ {
+ fprintf( stderr, "%s error: invalid object type\n", id);
+@@ -71,6 +73,8 @@
+ */
+ if( MGrBufferlen( paramPtr, MAXBUFFERSIZE ) < 1 )
+ {
++ fprintf( stderr, "%s error: attempt to place null data into record halted\n", id );
++ while( fflush( stderr ) );
+ assert(0);
+ }
+ fprintf( dbFileStream, "%s%c", paramPtr, 0 );
+@@ -85,6 +89,7 @@
+ {
+ fprintf( stderr, "%s error: fields added (%d) exceed field quantity (%d)\n did you forget to terminate MGdbAdd with a NULL field?\n",
+ id, idx, db->fieldQty );
++ while( fflush( stderr ) );
+ assert(0);
+ }
+ }