Replace the spacers between your hardwood floor and your brick wall with cork expansion strips. These strips hold your flooring in place while allowing the wood the freedom to contract and expand as moisture and temperature levels change in your room.
Measure the perimeter of your room and cut the molding to fit over the expansion gap between your flooring and your walls. Mark your molding with a pencil and use a jigsaw to cut it to shape. Use a miter box to cut 45-degree angles where your molding needs to fit into the corners of your room. Clamp your molding into place in your meter box and use a handsaw to cut along a 45-degree marker.
Apply a thick bead of caulking adhesive to the back of your molding and press it into place against your brick wall.
Apply a bead of decorator's caulk to the gap between your wall and your molding, and another along the gap between your molding and your hardwood floor. Press the caulk into place with a plastic putty knife and wipe away any residue with a damp cloth.