Skip to content
Permalink
Browse files
HAWQ-1839. fix memory leak in hdfsprotocol_blocklocation
  • Loading branch information
ztao1987 committed May 6, 2022
1 parent 04b8497 commit 73a4fbecd78ce86c651f57087297623a6044e86f
Showing 1 changed file with 2 additions and 2 deletions.
@@ -92,7 +92,7 @@ Datum hdfsprotocol_blocklocation(PG_FUNCTION_ARGS)
}

/* Clean up uri instance as we don't need it any longer */
pfree(uri);
FreeExternalTableUri(uri);

/* Check all locations to get files to fetch location. */
ListCell *lc = NULL;
@@ -222,7 +222,7 @@ Datum hdfsprotocol_blocklocation(PG_FUNCTION_ARGS)
}

/* Clean up URI instance in loop as we don't need it any longer */
pfree(uri);
FreeExternalTableUri(uri);

/* Clean up file info array created by the lib for this location. */
FscHdfsFreeFileInfoArrayC(&fiarray);

0 comments on commit 73a4fbe

Please sign in to comment.