Browse Source

workaround for empty #state.columns on equery completion

Anton Lebedevich 13 years ago
parent
commit
95f8dc6db0
1 changed files with 3 additions and 1 deletions
  1. 3 1
      src/pgsql_sock.erl

+ 3 - 1
src/pgsql_sock.erl

@@ -455,7 +455,9 @@ on_message({$D, <<_Count:?int16, Bin/binary>>}, State) ->
                       State#state.columns
               end,
     Data = pgsql_wire:decode_data(Columns, Bin),
-    {noreply, State#state{rows = [Data | State#state.rows]}};
+    {noreply, State#state{rows = [Data | State#state.rows],
+                          columns = Columns %TODO workaround for equery,execute
+                         }};
 
 %% PortalSuspended
 on_message({$s, <<>>}, State) ->