diff options
author | Rod Smith <rodsmith@rodsbooks.com> | 2018-07-05 16:50:13 -0400 |
---|---|---|
committer | Rod Smith <rodsmith@rodsbooks.com> | 2018-07-05 16:50:13 -0400 |
commit | 9ae60195b9d24c01f535ade5b7bcf0e63c0600be (patch) | |
tree | 3f7c35f56cb9222be3081c57b3f7d61af3390483 /gptpart.cc | |
parent | 8dab6f22ee54e63d98cf303d16702794d091bcbb (diff) | |
download | sgdisk-9ae60195b9d24c01f535ade5b7bcf0e63c0600be.tar.gz |
Added explicit copy constructors and made other tweaks to avoid
compiler complaints.
Diffstat (limited to 'gptpart.cc')
-rw-r--r-- | gptpart.cc | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -38,6 +38,15 @@ GPTPart::GPTPart(void) { memset(name, 0, NAME_SIZE * sizeof(name[0]) ); } // Default constructor +GPTPart::GPTPart(const GPTPart & orig) { + partitionType = orig.partitionType; + uniqueGUID = orig.uniqueGUID; + firstLBA = orig.firstLBA; + lastLBA = orig.lastLBA; + attributes = orig.attributes; + memcpy(name, orig.name, NAME_SIZE * sizeof( name[ 0 ] ) ); +} // Copy constructor + GPTPart::~GPTPart(void) { } // destructor |