That's a common edge bleeding artefact.
I had plenty of problems with them when I wrote my lightmapper.

A solution is to leave a gap of 2-3 pixels around each shape in your lightmap, then after you finished generating the entire lightmap, go back over it and extend the edges of all the shapes in your lightmap.

The way I did this is something like this:
- Colour in the background of your lightmap a rarely used colour, like (255, 0, 255) or something
- For each pixel of your lightmap:
--- if this pixel is (255, 0, 255) then
--- add up all adjacent pixels which are NOT (255, 0, 255)
--- colour this pixel the average of these colours.

And that should fix it.