diff options
-rw-r--r-- | src/atom.h | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -25,7 +25,8 @@ namespace Bu | |||
25 | Atom( const MyType &oth ) : | 25 | Atom( const MyType &oth ) : |
26 | pData( NULL ) | 26 | pData( NULL ) |
27 | { | 27 | { |
28 | set( *oth.pData ); | 28 | if( oth.pData ) |
29 | set( *oth.pData ); | ||
29 | } | 30 | } |
30 | 31 | ||
31 | Atom( const t &oth ) : | 32 | Atom( const t &oth ) : |
@@ -98,7 +99,8 @@ namespace Bu | |||
98 | 99 | ||
99 | MyType &operator =( const MyType &oth ) | 100 | MyType &operator =( const MyType &oth ) |
100 | { | 101 | { |
101 | set( *oth.pData ); | 102 | if( oth.pData ) |
103 | set( *oth.pData ); | ||
102 | 104 | ||
103 | return *this; | 105 | return *this; |
104 | } | 106 | } |