Commit Graph

13 Commits

Author SHA1 Message Date
Nathan Woods
e9b551bac9 [Imgtool] Bulk change: 'imgtool::image *' ==> 'imgtool::image &' 2016-10-16 10:07:32 -04:00
Nathan Woods
c58b56e0c6 [Imgtool] Changed the create/open callbacks to take 'imgtool::stream &&'
They always took ownership of the stream; this just makes it official.  Because the ownership would only traditionally happen if the open() or create() succeeded, I had to do a clumsy pattern where I call get() at the beginning of the callback to get the stream, but later on release() immediately prior to succeeding.
2016-10-15 17:52:34 -04:00
Nathan Woods
e77c24ce76 [Imgtool] Changed many 'imgtool::stream *' to 'imgtool::stream &' 2016-10-14 19:55:53 -04:00
Nathan Woods
d3567b0f71 [Imgtool] More C++-ification (imgtool_stream ==> imgtool::stream)
Still a bit of work to do, most notably around adoption of std::unique_ptr<>, which may be a challenge here on account of some assumptions regarding lifetime of streams by modules.
2016-10-12 07:20:39 -04:00
Nathan Woods
c5f7de716f [Imgtool] C++-ified a few more classes
imgtool_partition ==> imgtool::partition
imgtool_directory ==> imgtool::directory
2016-10-09 18:37:32 -04:00
R. Belmont
6595eae179 Merge pull request #1456 from npwoods/imgtool_image_cplusplus
Made imgtool_image (now imgtool::image) a "real" C++ class
2016-10-08 14:45:10 -04:00
Nathan Woods
4ea9bdd6c5 [Imgtool Mac Module] Fixed an unsigned overflow error that would causes crashes on 64 bit systems 2016-09-30 07:55:17 -04:00
Nathan Woods
baae7b926d Made imgtool_image (now imgtool::image) a "real" C++ class 2016-09-27 05:13:32 -04:00
Vas Crabb
889ecdfd4f Let's give the new srcclean a spin... 2016-08-02 16:59:02 +10:00
Miodrag Milanovic
9667c6a8cc std::min and std:max instead of MIN and MAX, also some more macros converted to inline functions (nw) 2016-07-31 14:41:02 +02:00
Vas Crabb
6a67de94f9 Fix up imgtool as well 2016-07-08 15:29:50 +10:00
Miodrag Milanovic
379581fb36 macro removal INLINE -> static inline (nw) 2015-12-12 08:58:57 +01:00
Miodrag Milanovic
7c19aac60e Rename *.c -> *.cpp in our source (nw) 2015-11-08 12:56:12 +01:00