1
0
mirror of https://github.com/pdf2htmlEX/pdf2htmlEX.git synced 2024-07-02 16:25:41 +00:00

clean code

This commit is contained in:
Lu Wang 2012-11-29 19:43:19 +08:00
parent ba77c1cc6c
commit 9d99fd9b82
3 changed files with 4 additions and 3 deletions

View File

@ -7,7 +7,7 @@ using std::string;
namespace pdf2htmlEX {
void create_directories(string path)
void create_directories(const string & path)
{
if(path.empty()) return;

View File

@ -12,7 +12,7 @@
namespace pdf2htmlEX {
void create_directories(std::string path);
void create_directories(const std::string & path);
bool is_truetype_suffix(const std::string & suffix);

View File

@ -17,8 +17,9 @@ public:
{
public:
guarded_pointer(string_formatter * sf) : sf(sf) { ++(sf->buf_cnt); }
guarded_pointer(const guarded_pointer & gp) : sf(gp.sf) { ++(sf->buf_cnt); }
~guarded_pointer(void) { --(sf->buf_cnt); }
operator char* () { return &(sf->buf.front()); }
operator char* () const { return &(sf->buf.front()); }
private:
string_formatter * sf;
};