diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2016-04-05 21:15:45 +0000 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2016-04-05 21:15:45 +0000 |
| commit | 020a96b4a89e5d9e38170a28bb9848519060bdca (patch) | |
| tree | 88a0110d2443ed5830bc0d2eb8c554b1fde3208d /src | |
| parent | f0f41708a44280cc22fa3557983833146d524544 (diff) | |
Fix more compiler warnings.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11536 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/Fl_PNG_Image.cxx | 2 | ||||
| -rw-r--r-- | src/Fl_Slider.cxx | 2 | ||||
| -rw-r--r-- | src/Fl_win32.cxx | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/Fl_PNG_Image.cxx b/src/Fl_PNG_Image.cxx index 0183e82a5..1d94e9803 100644 --- a/src/Fl_PNG_Image.cxx +++ b/src/Fl_PNG_Image.cxx @@ -115,7 +115,7 @@ void Fl_PNG_Image::load_png_(const char *name_png, const unsigned char *buffer_p FILE *fp = NULL; // File pointer int channels; // Number of color channels png_structp pp; // PNG read pointer - png_infop info; // PNG info pointers + png_infop info = 0; // PNG info pointers png_bytep *rows;// PNG row pointers fl_png_memory png_mem_data; int from_memory = (buffer_png != NULL); // true if reading image from memory diff --git a/src/Fl_Slider.cxx b/src/Fl_Slider.cxx index 705dc9692..e5f32ef01 100644 --- a/src/Fl_Slider.cxx +++ b/src/Fl_Slider.cxx @@ -269,7 +269,7 @@ int Fl_Slider::handle(int event, int X, int Y, int W, int H) { } int xx = mx-offcenter; - double v; + double v = 0; char tryAgain = 1; while (tryAgain) { diff --git a/src/Fl_win32.cxx b/src/Fl_win32.cxx index 8d7e220a1..33addd3f2 100644 --- a/src/Fl_win32.cxx +++ b/src/Fl_win32.cxx @@ -738,7 +738,7 @@ void Fl::paste(Fl_Widget &receiver, int clipboard, const char *type) { } else if (strcmp(type, Fl::clipboard_image) == 0) { // we want an image from clipboard uchar *rgb = NULL; - int width, height, depth; + int width = 0, height = 0, depth = 0; if ( (h = GetClipboardData(CF_DIB)) ) { // if there's a DIB in clipboard LPBITMAPINFO lpBI = (LPBITMAPINFO)GlobalLock(h) ; width = lpBI->bmiHeader.biWidth; // bitmap width & height @@ -1481,7 +1481,7 @@ static LRESULT CALLBACK WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lPar static int fake_X_wm_style(const Fl_Window* w,int &X,int &Y, int &bt,int &bx, int &by, DWORD style, DWORD styleEx, int w_maxw, int w_minw, int w_maxh, int w_minh, uchar w_size_range_set) { - int W, H, xoff, yoff, dx, dy; + int W = 0, H = 0, xoff = 0, yoff = 0, dx = 0, dy = 0; int ret = bx = by = bt = 0; int fallback = 1; @@ -1558,7 +1558,7 @@ static int fake_X_wm_style(const Fl_Window* w,int &X,int &Y, int &bt,int &bx, in //Proceed to positioning the window fully inside the screen, if possible //Find screen that contains most of the window //FIXME: this ought to be the "work area" instead of the entire screen ! - int scr_x, scr_y, scr_w, scr_h; + int scr_x = 0, scr_y = 0, scr_w = 0, scr_h = 0; Fl::screen_xywh(scr_x, scr_y, scr_w, scr_h, X, Y, W, H); //Make border's lower right corner visible if (scr_x+scr_w < X+W) X = scr_x+scr_w - W; |
