bayleeadamoss / zazu-clipboard

A clipboard manager for Zazu.
The Unlicense
14 stars 12 forks source link

Detecting images in clipboard is throwing errors in console #6

Open amjith opened 8 years ago

amjith commented 8 years ago

When there is no image in the clipboard this line to detect if the image is empty is causing a possible memory leak. This also results in printing of an error to the electron console.

https://github.com/tinytacoteam/zazu-clipboard/blob/master/src/monitor.js#L24

016-07-31 22:05:28.037 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.145 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.254 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.363 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.474 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.583 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.691 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.
2016-07-31 22:05:28.797 Electron Helper[2001:3225347] Can't allocate a new block for a pasteboard. Creation of a new Pasteboard will fail.