Memory Leak? Shift Register Testing

So I wrote the program:

Main:

#include "zShift.h"

int main()
{	
	init();
	zshift.init();

	uint8_t dynByte;

	while(1)
	{
		zshift.shift(dynByte);
		HDelay(3);
		dynByte++;
	}
}

zShift.h:

#ifndef _ZSHIFT_h
#define _ZSHIFT_h

#if defined(ARDUINO) && ARDUINO >= 100
	#include "Arduino.h"
#else
	#include "WProgram.h"
#endif

/**********************************************************************************
* Software SPI Pin Settings
*********************************************************************************/
#define SPIPORT		PORTB
#define SPIPINPORT	PINB	//The Port that the Pins are on.  
#define LatchPin	2	//_RCLK  Shift register clock pin		
#define DataPin		3	//SER DS Serial data input				
#define ClockPin	5

/**********************************************************************************
* Macros
*********************************************************************************/
#define LATCHMASK	(1 << LatchPin)        //_SRCLK SS Storage register clock pin	
#define MOSIMASK	(1 << DataPin)         //BIT3//DataPin	//SER DS Serial data input				
#define CLOCKMASK	(1 << ClockPin)        //ClockPin//_RCLK  Shift register clock pin	

#define LATCH	(SPIPINPORT &=~ LATCHMASK)		//CLR(SPIPINPORT,LatchPin)
#define unLATCH	(SPIPINPORT |= LATCHMASK)	//SET(SPIPINPORT,LatchPin)
#define PULSE	{ tggl(SPIPINPORT,ClockPin); tggl(SPIPINPORT,ClockPin); }

#define tggl(port,bit) (port)^=(1<<(bit))

class zShiftClass
{
 private:

 public:
	void init();
	void shift( uint8_t value );
};

extern zShiftClass zshift;

#endif

zShift.cpp:

#include "zShift.h"

void zShiftClass::init()
{
	DDRB |= ( LATCHMASK | MOSIMASK | CLOCKMASK );
	SPIPINPORT &= ~( MOSIMASK | CLOCKMASK );
}

void zShiftClass::shift(uint8_t value)
{
	LATCH;
	for (uint8_t i = 0; i <= 7; i++) 
	{	
		if( !!(value&(1<<i)) == true)	//If value is not a 1, turn off MOSIMASK
		{ SPIPORT |= MOSIMASK; } 
		else	
		{ SPIPORT &= ~MOSIMASK; } 		

		PULSE;	//Pulse the Clock
	}
	unLATCH;
}

zShiftClass zshift = zShiftClass();

After the program runs through about 5 iterations it just locks up. The exact point it ends is the 5th iteration at a byte value of 13. Is there a memory leak? Why is it doing this?

Figured it out.

Changing this:

define SPIPORT PORTB

define SPIPINPORT PINB

To This:

define SPIPORT PORTB

define SPIPINPORT PORTB

Fixed it. Now I just have it:

define SPIPINPORT PORTB